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

Problem With RadDataPager & VirtualQueryableCollectionView

7 Answers 231 Views
Data Virtualization
This is a migrated thread and some comments may be shown as answers.
Stephen
Top achievements
Rank 1
Stephen asked on 14 Apr 2011, 10:49 AM
I have an issue with the DataPager when used with the VirtualQueryableCollectionView.

When paging the DataPager creates the correct number of pages and allows me to correctly navigate through them. When changing pages the VirtualQueryableCollectionView loads the data as expected, this is populated in the list box as expected. The list box moves to the correct page location but is not displaying just the page size, its displaying all records from that point.

If I change from the ListBox to the telerik RadGridView the grid view displays 5 items as expected.

In my XAML page i have...

<t:RadDataPager x:Name="dataPager" Source="{Binding MyDataSource}" PageSize="5" NumericButtonCount="10" AutoEllipsisMode="Both" /> 
    
<ListBox  ItemsSource="{Binding PagedSource, ElementName=dataPager}"/>

In my data model I something like the following...

MySource = new VirtualQueryableCollectionView<SomeObject> { LoadSize = 30, VirtualItemCount = 100 };
MySource.ItemsLoading += (s, e) =>
{
   _dataManager.GetMyData(e.StartIndex, e.ItemCount).CompletedWithOutErrors += operation =>
   {
     var tempData = operation.Entities.Single();
  
     if (tempData.TotalCount != MySource.VirtualItemCount)
     {
        MySource.VirtualItemCount = tempData.TotalCount;
     }
                         
     MySource.Load(e.StartIndex, tempData.DataItems);
   };
};
  
...
  
public VirtualQueryableCollectionView<SomeObject> MySource { get; set; }

Any ideas as to what i'm doing wrong here.

Cheers

Stephen

7 Answers, 1 is accepted

Sort by
0
Vlad
Telerik team
answered on 14 Apr 2011, 12:19 PM
Hello,

 As far as I can see you have set PageSize="5" and LoadSize = 30. In this case collection will load 30 items - you will get 6 pages loaded.

Best wishes,
Vlad
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
Stephen
Top achievements
Rank 1
answered on 14 Apr 2011, 12:43 PM
I've already tried quite a few combinations of PageSize, LoadSize etc none make any difference to the issue i'm having.

This loads 30 items in a single load from the back end, until I browse to the 7th page where it loads the next 30 as expected.

The grid view shows 5 items as i'd expect but the ListBox and RadTileView both display the full number of items in the virtual collection (which is over 5000).

The items that haven't yet been loaded have empty data in the ListBox but are rendered (which means its rendering all 5000+) instead of the expected 5.

Cheers

Stephen
0
Vlad
Telerik team
answered on 14 Apr 2011, 12:47 PM
Hi Stephen,

 Can you post more info about the version? Is it our Q1 2011?

Greetings,
Vlad
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
Stephen
Top achievements
Rank 1
answered on 14 Apr 2011, 12:51 PM
We have the latest version installed, Q1 2011.
The components have version number of 2011.1.315.1040

Cheers

Stephen
0
Vlad
Telerik team
answered on 14 Apr 2011, 01:39 PM
Hello Stephen,

 The problem is identified and fixed immediately! The fix will be part of our upcoming service pack early next week. 

I've added 2000 Telerik points to your account. 

Regards,
Vlad
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
ScimarGreg
Top achievements
Rank 2
answered on 27 Apr 2011, 05:10 PM
Thanks for bringing this up Stephen. We're having the same exact problem right now as well.
0
Charlie
Top achievements
Rank 2
answered on 06 May 2011, 06:54 PM
Thanks Stephen for being this up.  I was having the same problem.

Thanks,

Charlie J.
Tags
Data Virtualization
Asked by
Stephen
Top achievements
Rank 1
Answers by
Vlad
Telerik team
Stephen
Top achievements
Rank 1
ScimarGreg
Top achievements
Rank 2
Charlie
Top achievements
Rank 2
Share this question
or