I'd like to sort a column of names completely within my own code when the user clicks the column header. It's a list of names that should mostly be sorted alphabetically except for a small number of names that should be grouped (these groups are specified in a command line argument, if you're curious). Is there some way I can override the sorting event for a particular column with my own method? Ideally I would get the unsorted list as an event argument and then return the sorted list at the end.
Thanks.
Thanks for checking in. I was able to finish this task using the instructions you provided. Much obliged.
Hello,
I am just checking about the progress of this issue. Let me know If you need my further assistance on this issue?
Thank you for using Infragistics Components.
Hello,
UltraGridColumn object has a property named SortComparer which is used to perform custom sort comparisons when sorting rows by this column. The values passed in the Compare method of the IComparer will be two UltraGridCell objects. On the following link, you will find more information about this property and also code, which shows you how to sort rows with a custom comparer:
http://help.infragistics.com/Help/NetAdvantage/WinForms/2011.2/CLR2.0/html/Infragistics2.Win.UltraWinGrid.v11.2~Infragistics.Win.UltraWinGrid.UltraGridColumn~SortComparer.html
Please let me know if you have any further questions .