Hi Magesj,

The GridView control has the properties to count the row and columns in the GridView control.

int rowCount = GridView1.Rows.Count;
int columnCount = GridView1.Columns.Count;

The Rows.Count and Columns.Count returns the integer property.

If it is useful then mark it as "Accepted Answer"