We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Grouping Engine - Sort By Group Count

Thread ID:

Created:

Updated:

Platform:

Replies:

42569 Apr 1,2006 12:28 AM UTC Apr 11,2006 11:53 PM UTC WinForms 6
loading
Tags: Grouping
Brian Schlatter
Asked On April 1, 2006 12:28 AM UTC

Hi, Is it possible to sort individual groups by the number of records they hold? I''m using a Syncfusion.Grouping.Engine and have added a group like: engine.TableDescriptor.GroupedColumns.Add("EventName"); I''m trying to build a histogram of all the "EventName" counts but I need the chart do be displayed in decending order. Is this possible? Thanks, Brian

Administrator [Syncfusion]
Replied On April 3, 2006 06:40 AM UTC

Hi Brain, Thanks for being patient. Currently there is no in-built support for this type of sorting. To achieve this, you will have to use custom sorting. Please refer to this article for more details. I will work out a sample and update you on it soon. Best regards, Madhan

Administrator [Syncfusion]
Replied On April 3, 2006 06:43 AM UTC

Hi Brain, Sorry for the broken link. Here is the path for the article [ www.syncfusion.com/Support/article.aspx?id=10507 ]. Best regards, Madhan

Jayakumar Natarajan [Syncfusion]
Replied On April 4, 2006 09:22 PM UTC

Hi Brain, You can acheive this by SortBySummaryInCaption approach. Please refer this shipping sample - Windows\Grid.Grouping.Windows\Samples\SortBySummaryInCaption. This sample lets you have a summary in caption and sort by the summary. You can have the "Count" as summary and not show the count in the caption. It will be grouped and sorted by record count. Please refer the attached sample. Best regards, Jay forumm_42569.zip

Brian Schlatter
Replied On April 6, 2006 10:07 PM UTC

Thanks for the help but this was not exactly what I was looking for. I am strictly using a Syncfusion.Grouping.Engine object to filter and sort data internally. I am not using a GridControl of any sort. I wish to group the engine on a particular attribute of the datasource and sort the engine based on the number of values within each group. Can this be done with the Syncfusion.Grouping.Engine object? After sorting the groups based on their count, I''d like to show a chart (using your ChartControl) with the X-Axis being the group''s category and the Y-Axis displaying the number of elements within that group. Is this possible? Thanks again, Brian

Administrator [Syncfusion]
Replied On April 10, 2006 07:12 AM UTC

Hi Brain, I am sorry for the delayed response. The groups can be sorted by its record count by specifying our own custom comparer to the sortColumnDescriptor.GroupSortOrderComparer. Sample attached. Regards, Calvin.

42569.zip

Brian Schlatter
Replied On April 11, 2006 11:53 PM UTC

Perfect. Thank you very much Calvin.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;