PAGING not working in ASP DataGrid

  • Thread starter Thread starter getziiiiiiiiiii
  • Start date Start date
G

getziiiiiiiiiii

Hi There. . I need some help in paging (which is not working) in
ASP:DATAGRID

My Data source id is a function which returns DataTable to this
datagrid.
Do i need a code behind to get the next page working?

thanks for help.

this is how my data grid look like:

<asp:datagrid
ID="GridView"
DataSourceID="ObjectDataSource"
DataKeyField="id"

AllowSorting="True"
runat="server"
AutoGenerateColumns="false"

OnSelectedIndexChanged="GridView_SelectedIndexChanged"
AllowPaging="True" PageSize="5"
PagerStyle-Mode="NumericPages"
 
When you say it isn't working - exactly what do you mean?
Are you getting an error?

--
David Wier
MVP/ASPInsiderhttp://aspnet101.comhttp://aspexpress.com









- Show quoted text -


In the PageIndexChanging event, set the PageIndex of the grid to be
e.NewPageIndex.
 
Back
Top