|
 |
aspx thread: Datagrid Paging
Message #1 by "McCloy, Russell" <Russell.McCloy@B...> on Thu, 14 Mar 2002 12:26:58 +1100
|
|
Hello all,
I am using visual studio.NET.
I have a datagrid and have paging turned on.
It looks great and displays the correct amount of records on my web page.
I have a sub that fires on
======================
myDataGrid_PageChanger
======================
When I click on my pager the page reloads but I still see the same records.
Any hints would be greatly appreciated.
thanks
RuSs
Message #2 by "Marcus Taylor" <mtaylor@i...> on Thu, 14 Mar 2002 09:08:42
|
|
Russ,
I had a similar problem with paging datagrids, I found that you need to
use one of the events raised by the page. In other words, put
a "onPageIndexChanged = methodname" in the datagrid tag using the HTML
editor. In the method on the code behind page set the worklist's current
page index and then reload the datagrid. Something like:
Sub datagrid1_Paged(ByVal sender As Object, ByVal e As
DataGridPageChangedEventArgs)
datagrid1.CurrentPageIndex = e.NewPageIndex
'then code to reload and rebind the datagrid here
End Sub
hope this makes sense.
Rgds
Marcus
> Hello all,
>
> I am using visual studio.NET.
>
> I have a datagrid and have paging turned on.
> It looks great and displays the correct amount of records on my web page.
>
> I have a sub that fires on
>
> ======================
> myDataGrid_PageChanger
> ======================
>
> When I click on my pager the page reloads but I still see the same
records.
> Any hints would be greatly appreciated.
> thanks
>
> RuSs
|
|
 |