Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Grid Paging
Message
From
18/05/2004 11:43:10
 
 
To
18/05/2004 11:23:21
Bill Benton
North Florida Software Services
Middleburg, Florida, United States
General information
Forum:
ASP.NET
Category:
The Mere Mortals .NET Framework
Title:
Miscellaneous
Thread ID:
00904894
Message ID:
00904967
Views:
20
This message has been marked as the solution to the initial question of the thread.
Bill,

>>
>>I have implemented paging using the mmdatagrid and may be able to help.
>>
>>Can you be more specific about the problems you are having? What have you tried and what errors or behaviors are you seeing?
>
>I have my grid displaying nicely, but whenever I click on the '2' page, it just recycles back to page 1. There is no way to advance to page 2. I checked out the MS web page that addresses the Web Grid, which I understand the mmDataGrid is subclassed from, and they are stating that paging is a default behavior, and shouldn't need additional code, unless you are doing custom paging.
>
>All I am doing is plugging in the data from the business class. I have no more code that I have added than that.
>
>By the time I figure out all of the nuances of this .NET platform, I don't think I'll have too much hair left.
>
>Any help you could provide would be greatly apprecieted.


Sounds like maybe you need to add code to the PageIndexChanged method. To create the method and pass the appropriate parameters, select your grid in the IDE and open the properties window. Click on the lightning bolt icon to view events. Double click the PageIndexChanged event to create the stub for your code.
private void mmdatagrid1_PageIndexChanged(object source, System.Web.UI.WebCOntrols.DataGridPageChanged(EventArgs e)
{
} 
Then you'll need to add some some code similar to the following in the method stub;
private void mmdatagrid1_PageIndexChanged(object source, System.Web.UI.WebCOntrols.DataGridPageChanged(EventArgs e)
{
     // set the current page     
     this.mmdatagrid1.CurrentPageIndex = e.NewPageIndex;

     //rebind the grid
     this.BindControl(this.mmdatagrid1);
}
Kendall Webb
Senior Software Engineer
MCAD.Net/MCSD.Net
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform