How to Fetch All Rows Of Gridview When Paging is Enabled??
asp.net
Solution
We disable paging temporarily and will re-bind the grid so that now we have access to all records in the datasource not just current page records.
Once gridview is binded with all records, you can iterate through gridview rows.
Once we are done with our task, we re-enable paging and rebind the grid.
Here the way to tackle with your condition:
protected void Page_Load(object sender, EventArgs e)
{
GridView2.AllowPaging = false;
GridView2.DataBind();
// You can select some checkboxex on gridview over here..
GridView2.AllowPaging = true;
GridView2.DataBind();
}
Problem
How to Fetch All The rows of gridview when paging is enabled?. it is allowing to fetch only current fetch rows not entire gridview rows.