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

Programmatic grouping missing aggregate functions

2 Answers 62 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Geoff Smith
Top achievements
Rank 1
Geoff Smith asked on 30 Sep 2010, 09:34 AM
Hi,

I have some functionality that sets up the grouping in a grid with some code. I create a GroupDescriptor and add it to the grid's GroupDescriptors. However, when I group this way, rather than by dragging a header into the group panel, the aggregate functions defined in my GridViewDataColumns are not applied. 

I'm guessing that I have to manually add all these aggregate functions to my group descriptor. However, I wanted to check if there is an easier way.

Thanks!

2 Answers, 1 is accepted

Sort by
0
Accepted
Pavel Pavlov
Telerik team
answered on 30 Sep 2010, 09:56 AM
Hello Geoff Smith,

Indeed when grouping programmatically , you will need to take care to add the aggregates.

For convenience when the user groups by dragging , aggregates are automatically set.
When you do it programmatically - for more flexibility the choice is yours - to add or not aggregate functions.

So in your case the standard approach is - when you add a GroupDescriptor to populate its aggregate functions.

Kind regards,
Pavel Pavlov
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
Geoff Smith
Top achievements
Rank 1
answered on 30 Sep 2010, 09:57 AM
Sounds good - thanks for the confirmation :)
Tags
GridView
Asked by
Geoff Smith
Top achievements
Rank 1
Answers by
Pavel Pavlov
Telerik team
Geoff Smith
Top achievements
Rank 1
Share this question
or