Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
1235
XamComboEditor sort by DisplayMember
posted

Hello,

i got a XamComboEditor inside a XamDataGrid with a LookUpList Int / String. (It works fine)

If i sort after this field, its randomly before or after the DisplayMember is subsituted by the text. (The LookUpList ItemSource is set only once at start, so its always there already.) I saw this in GroupByRecord.Description, while override the GroupByComparer, trying to workaround this..

Shouldnt it always be sorted after subsituted by text. And if not, is there an event i can listen for after loaded a new ItemSource to the Grid? (Binding)

xaml:

 


c#:
_grid.FieldLayouts[0].SortedFields.Clear();
_grid.FieldLayouts[0].SortedFields.Add(new FieldSortDescription("NrID", System.ComponentModel.ListSortDirection.Ascending, true));
_grid.Records.RefreshSort();

Greetings
KiTs 

Parents
  • 34510
    Offline posted

    Hi Joerg,

    I'm not really sure what exactly you mean by sorting after a field and it randomly being before or after the display member is substituted.  If I add a XamComboEditor to a Field as the editor and I give it the items source, once I run your code for sorting and grouping the field I don't see anything out of the ordinary.  I don't notice anything being substituted.  Can you take a look at my sample and modify it to reproduce your issue, then send it back to me?

    DataGridSorting.zip
Reply Children