Hi,
I am using UltraGird v6.3 windows control to display huge number of records but it takes lot of time to bind all the records in a single call. I did not find any default pagination property in control.
I would appreciate if any body can guide me how we can implement pagination in UltraGrid control provided all the functionality (like grouping columns, moving columns, sotring etc.) of UltraGrid control should work as expected.
WinGrid does not have any paging functionality. You might want to look into the Load-On-Demand feature of the UltraDataSource component, though. This allows yuo to only load into the grid the rows that are needed, rather than all of them. Thereis a sample included with NetAdvantage which is call the Million Rows sample and demonstrates a grid with a million rows in it.
Actually, I think the sample is called "Virtual Mode Sample" and it's under the UltraDataSource samples.
Thanks Mike for your reply.
From where I can download the sample code. Could you send me the link?
Hi Fady!A lot of time passed since I wrote this message! I am glad that you found it usefull.You can found attached a newer version with some bugs fixed.
You can just substitute the UltraGridPaginated control!ByeGianni
Thanks a lot Gianni
Hi everybody, I wrote and attached a sample that provides a paginated UltraGrid control.It is simple and not deeply tested. I hope this could help anybody want to paginate. This little project wants to be just a starting point to address the pagination, I am sure it could be improved (bugs are just behind the corner), expanded (I just managed single band grids) or even re-make (I'm interested in different solutions).About grouping, it would be too expensive (in time) for me, to realize an elegant and working pagination; because in my case the user rarely groups grid columns, I decided to ask the full data loading at the first request of grouping, warning the user about needed time with a MessageBox. Filter and sort are fine.Opening the UltraGridPaginated control code, in the beginning you will find some constants. They could be changed to tune the pagination for different situations. Value I set are pretty good for any generic cases.If anybody will try out this control and find any bugs, errors, doubts, please report that, it would be useful and I will look at that in the first free time spot I have (that could mean very long time :) )...ByeGianni
Hi, I made some changes and inserted a grid.Rows.Refresh(ReloadData) making it to work.Had no time to check if similar changes could solve the problem in the "one million rows" sample.If I will obtain a good working sample project I will post it so anybody want to paging can have a starting sample to follow and to improve. probably the hardest issue will be to manage the grouping...ByeGianni
Hi Mike,
I'm trying to paginate too. I'm following the way used in the "one million row example" with the support of a UltraDataSource.
Everything seemed to work well until I started to test/set the filtering feature. When a filter is active (I just written a letter on a string typed column, meaning "starts with") the CellDataRequest event of the UltraDataSource is called repeatedly.Not only for row into view, but for pretty all of them? I can not understand very well what's happening, but some malfunction seems to intervene.
The same functionality do not work on the "one million rows" sample too! You can try to start the "one milion rows" sample, then choose a column, for example "Hexadecimal", then write a number, for example 5, in the correspondent filter row column. It will filter rows that start with "5". Now with the mouse move the scroll bar in the average middle of the vertical space... It will flick and after a while (3-4 second) the grid will position on the first row again. This behavior is probably relevant with the problem I'm facing in my testbed...I can not get rid of this, could you give me any advices?Thanks in advanceGianni