I am working with Telerik WPF controls, RadGridView, RadDataPager and VirtualQueryableCollectionView<T>.
The PageCount of RadDataPager is incorrect once i filtered the data via RadGridView header. The PageCount is
always 1. please find attached image screenshot.
I do not know how to fix this issue. In following code, i set the VirtualItemCount value as new value but the RadDataPager show me 1 as PageCount. I could not move to next page.
Assembly version is: 2011.3.1220.40
The PageCount of RadDataPager is incorrect once i filtered the data via RadGridView header. The PageCount is
always 1. please find attached image screenshot.
I do not know how to fix this issue. In following code, i set the VirtualItemCount value as new value but the RadDataPager show me 1 as PageCount. I could not move to next page.
Assembly version is: 2011.3.1220.40
<telerik:RadGridView x:Name="GridView" ItemsSource="{Binding DataView}" Width="700" MinHeight="386" MaxHeight="500" .........</telerik:RadGridView><telerik:RadDataPager PageSize="100" Grid.Row="1" Source="{Binding DataView}" />public VirtualQueryableCollectionView<VSOEChageItemViewModel> DataView { get { if (_DataView == null) { _DataView = new VirtualQueryableCollectionView<VSOEChageItemViewModel>() { LoadSize = 40, VirtualItemCount = 40 }; _DataView.ItemsLoading += DataViewItemsLoading; } return _DataView; } private set { if (_DataView != null) { _DataView.ItemsLoading -= DataViewItemsLoading; } _DataView = value; if (_DataView != null) { _DataView.ItemsLoading += DataViewItemsLoading; } } }private void DataViewItemsLoading(object sender, VirtualQueryableCollectionViewItemsLoadingEventArgs e) { string filertString = GetFilertString(); var sort = DataView.SortDescriptors; var sortString = sort.ToDynamicLinq(); if (!string.IsNullOrEmpty(sortString)) sortString = sortString.Remove(0, sortString.IndexOf(".") + 1); int allCount = 0; List<VSOEChageItemViewModel> dd1 = LoadData(filertString, sortString, e.StartIndex, e.ItemCount, out allCount); if (allCount != DataView.VirtualItemCount) { DataView.VirtualItemCount = allCount; } DataView.Load(e.StartIndex, dd1); }