C# – Select Particular Row In Gridview

asp.netcgridview

I am using a GridView and a DataTable to fill the grid. I am also using custom paging.

Using the search feature of the GridView, I provided a textbox on each field for searching the records in the grid. If that record is found, that record gets selected.

I'm having an issue with paging where when I loop through the rows of the grid, the loop only displays page row if the data is on another page. How can I select that row to go on that page?

Best Answer

You have to select the page: GridView1.PageIndex. You might have to do more, depending on how you are binding the grid.

Related Topic