i have some data in the datagridview..now i want to delete the total data from the datagridview ..how can i do that ..plz give me reply

i have some data in the datagridview..now i want to delete the total data from the datagridview ..how can i do that ..plz give me reply

Bounded datagridivew use,

dataGridView1.DataSource=null;

Unbounded datagridView use,

dataGridView1.Rows.Clear();
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.