| How to Clear or blank the GridView data?
Below are the different methods to clear or blank Gridview with very less line of code
(1)First Method
GridView1.DataSource = null;
GridView1.DataBind();
(2)Second Method
GridView1.Rows.Clear();
GridView1.Refresh();
(3)Third Method
dataGridView1.Rows.Clear()
dataGridView1.DataBind();
(4)Fourth Method
dataGridView.DataSource=null;
dataGridView.Rows.Clear(); | | |