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. Image for the cookie policy date
close icon

GridGroupingControl - group one column, sort group using another column

Is there a way to group on one column and then use the values in another column to sort the group?

For instance, if there is a Systems table with a SystemID column and a Rank column, the grouping would occur on SystemID and then Rank would determine the order the SystemID's would be displayed.

Systems

SystemID, Rank
SystemA, 2
SystemB, 1
SystemC, 3

So with the above data, if the sort was ascending, then the ggc would display:

SystemB, SystemA, SystemC

instead of:

SystemA, SystemB, SystemC

I added a Rank as a SortedColumn to the ggc but that did not work.

Thanks,
Greg

1 Reply

LS Lingaraj S Syncfusion Team December 23, 2009 09:07 AM UTC

Hi Greg,

Thank you for your interest in Syncfusion products.

Please try using CustomerComparor in GridGroupingControl Sort/Grouped column to achieve your requirement as shown in attached sample.

Refer the sample from below link:
http://help.syncfusion.com//samples/Grid.Windows/GGCSamples/GGCGroup/main.htm

Please let me know if you have any queries.

Regards,
Lingaraj S.

Loader.
Live Chat Icon For mobile
Up arrow icon