I have displayed the data from the DB to the GridView made a column in the GridView as HyperLink allowed paging by setting the Allow Paging Property to "True". By clicking on the page no link I have to view other records. For that I have given the coding as
protected void GridView1_PageI ndexChanging(ob ject sender, GridViewPageEve ntArgs e)
{
GridView1.PageI ndex = e.NewPageIndex;
GridView1.DataB ind();
}
When I run, It shows the following error
The GridView 'GridView1' fired event PageIndexChangi ng which wasn't handled.
But when I set the Datasource Property of the GridView, then paging is running properly but the hyperlink button in the GridView is getting hided i.e the data without the hyperlink is getting displayed. The thing is I want both the page event to occur & the hyperlink field should also get displayed.
protected void GridView1_PageI ndexChanging(ob ject sender, GridViewPageEve ntArgs e)
{
GridView1.PageI ndex = e.NewPageIndex;
GridView1.DataB ind();
}
When I run, It shows the following error
The GridView 'GridView1' fired event PageIndexChangi ng which wasn't handled.
But when I set the Datasource Property of the GridView, then paging is running properly but the hyperlink button in the GridView is getting hided i.e the data without the hyperlink is getting displayed. The thing is I want both the page event to occur & the hyperlink field should also get displayed.
Comment