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

RadGridView.GroupDescriptors & DataPaging

5 Answers 167 Views
GridView
This is a migrated thread and some comments may be shown as answers.
lina fetisova
Top achievements
Rank 1
lina fetisova asked on 04 Jun 2010, 07:17 AM
Good day!
I've done some grouping in my RadGridView this way:
<telerikGridView:RadGridView.GroupDescriptors>
                <telerikData:GroupDescriptor Member="DtEvent.Date"
                                    SortDirection="Descending">
                    <telerikData:GroupDescriptor.AggregateFunctions>
                        <telerikData:CountFunction Caption="Всего выгрузок: " />
                    </telerikData:GroupDescriptor.AggregateFunctions>
                </telerikData:GroupDescriptor>
                <telerikData:GroupDescriptor Member="Sales.Client.Name"
                                    SortDirection="Descending">
                    <telerikData:GroupDescriptor.AggregateFunctions>
                        <telerikData:CountFunction Caption="Всего выгрузок: " />
                    </telerikData:GroupDescriptor.AggregateFunctions>
                </telerikData:GroupDescriptor>
            </telerikGridView:RadGridView.GroupDescriptors>

and now my DataPager don't work right =(
<data:DataPager x:Name="dataPager" Grid.Row="3" PageSize="100" Margin="0,0,0,0" HorizontalAlignment="Left" Grid.ColumnSpan="2" Grid.Column="0"  DisplayMode="FirstLastPreviousNextNumeric"  Visibility="Collapsed"/>

QueryableCollectionView qcv = new QueryableCollectionView(e.Result);dataPager.Source = qcv;<br>grStatistics.ItemsSource = qcv;
dataPager.Visibility = (dataPager.PageCount == 1) ? Visibility.Collapsed : Visibility.Visible; 


it does not show the number of pages correctly. Visibility works incorrect too.
how can I configure it?


5 Answers, 1 is accepted

Sort by
0
Rossen Hristov
Telerik team
answered on 04 Jun 2010, 07:27 AM
Hi lina fetisova,

This behavior is by design.

When you want to page a grouped grid the behavior is too ambiguous: should the grid group only the items in the current page, or group all the items and have the pager split one group in several pages?

What should happen if the page size is set to 1 for example. Should this get only one record? Or only one group? In other words, there is no clear logic about paging a grouped grid, or grouping a paged grid if you prefer.

You can think of paging occurring first (i.e. get a "PageSize" number of entities from a DomainDataSource for example). After the data (i.e. page 1 containing 10 records) has "arrived" on the client grouping is performed over this and only this data. In other words, the grid is not aware of the large-scale picture -- it only knows about 10 records at a time, it does not know that this is part of a larger set of data residing on the server for example. That is why it is grouping what it currently has as its items source, which is page one containing the 10 records.

As for the Visibility issue, could you please explain how does not it work correctly. What is the value of (dataPager.PageCount == 1)? And what is the Visibility of the pager?

All the best,
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
Prakash
Top achievements
Rank 1
answered on 20 Sep 2010, 01:15 PM
could u please provide me sample regarding
group all the items and have the pager split one group in several pages.

with Grouping Row content should contain as "Continuation..." if there is any records under the group which is more than the page size..
0
Rossen Hristov
Telerik team
answered on 20 Sep 2010, 01:49 PM
Hello Prakash,

That is not possible.

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
Sean
Top achievements
Rank 1
answered on 09 Mar 2011, 12:03 AM
Hi,

I wanted to request information on whether this limitation is still in the upcoming Q1 2011 release.

For information on our perspective... Server side operations (paging primarily) is intended to improve performance, not change the primary user experience.  In a perfect world, the use case / experience would be identical whether the data is paged or not.  with unpaged data, the user experience allows them to group by a particular column and return a unique list of values from that column, along with the number of occurrences for each item in that list.  When expanding that item, all items within the group are returned.  It would seem that you should be able to add a groupdescriptor to a paged dataset and have it function similarly?

Thanks for your feedback!

Sean
0
Rossen Hristov
Telerik team
answered on 09 Mar 2011, 09:22 AM
Hi Sean,

I totally agree with you that this would be very nice to have in a perfect world, but unfortunately the reality is that there is no way to implement this.

Greetings,
Ross
the Telerik team
Registration for Q1 2011 What’s New Webinar Week is now open. Mark your calendar for the week starting March 21st and book your seat for a walk through all the exciting stuff we ship with the new release!
Tags
GridView
Asked by
lina fetisova
Top achievements
Rank 1
Answers by
Rossen Hristov
Telerik team
Prakash
Top achievements
Rank 1
Sean
Top achievements
Rank 1
Share this question
or