This is a migrated thread and some comments may be shown as answers.

Data virtualization using pages

4 Answers 104 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Beryl Wilson
Top achievements
Rank 1
Beryl Wilson asked on 13 Nov 2010, 09:51 PM
We have IEnumerable<Product> object whose count is 3000. It would take 800 milliseconds to loop through 30 objects. But would take around 1 minute to loop through 3000 objects. I created a RadDataPager and set the page size as 30 and the source to IEnumerable<Product> object whose count is 3000. Then I had set the ItemSource of the grid as PagedSource. I expect RadDataPager to loop through only 30 objects at any given point in time. But unfortunately it loops through entire 3000 objects and defeats the purpose of paging. Am I missing some thing.

Thanks in advance,
Beryl Wilson

4 Answers, 1 is accepted

Sort by
0
Beryl Wilson
Top achievements
Rank 1
answered on 14 Nov 2010, 07:21 PM
Need help!!! Please let me know if am not clear. I'm almost stuck here and in the process of finalizing a 3rd party grid control.
0
Rossen Hristov
Telerik team
answered on 15 Nov 2010, 09:28 AM
Hi Beryl Wilson,

Can you please open a separate support ticket and send us the sample project. We will then examine it and see what is going on.

Thanks in advance. We are looking forward to hearing from you.

Best wishes,
Ross
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Rossen Hristov
Telerik team
answered on 15 Nov 2010, 09:51 AM
Hi Beryl Wilson,

Actually, you do not need to send us a project.

The pager needs to know the total count of the items so it can calculate the number of pages. It takes the total count and divides it by the page size.

In case you want to achieve endless paging, i.e. where the total number of pages is not known, you will have to implement the IPagedCollectionView interface and return appropriate values. For example, for the ItemCount property you can return hard-coded 3000 if you are sure that they will be always 3000. By implementing the IPagedCollectionView you will ensure that the pager will communicate with your implementation.

A similar implementation an be seen in the online example called Endless Paging.

My blog post explains the basic stuff about paging.

Regards,
Ross
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Beryl Wilson
Top achievements
Rank 1
answered on 16 Nov 2010, 05:24 PM
Thanks for your reply. I would try this way and would let you know about the same.
Tags
GridView
Asked by
Beryl Wilson
Top achievements
Rank 1
Answers by
Beryl Wilson
Top achievements
Rank 1
Rossen Hristov
Telerik team
Share this question
or