SfListView with a SortDescriptor doesn't always apply

Hello,

I use a SfListView with a SortDescriptor, with a custom Comparer.
It works fine at first look (sorting work when adding a new object for instance), but sometimes when I modify some collection's object's properties which affect sorting, the sorting is forgot and the list shows the real collection order (which is not sorted), without even calling the Comparer function. If a restart the app or add a new object to the collection, the sort work great again.

How can I fix that please ?

Thanks

3 Replies

RS Rawoof Sharief Muthuja Sherif Syncfusion Team May 14, 2018 12:43 PM UTC

Hi Thomas,  
  
We have checked the reported query from our end.We would like to let you know that you can achieve your requirement by defining the property LiveDataUpdateMode to AllowDataShaping as like below example. If apply sorting, the updated item will sorted and also it will be applicable for grouping and filtering.   
  
Code Example[C#]:  
public GroupingPage()  
{  
   InitializeComponent();  
   listView.DataSource.LiveDataUpdateMode = LiveDataUpdateMode.AllowDataShaping;  
}  
  
Also, We have prepared a sample to achieve your requirement for your reference and you can download it from below link.  
  
  
Please let us know if you require further assistance.  
  
Regards,  
Rawoof M  



TH Thomas May 15, 2018 02:16 PM UTC

Hello,

Thank you for your answer, your trick seems to fix my problem, great !
You definitely should update & complete your documentation, it will avoid wasting our time to all on that kind of matter.

Have a nice day.


RS Rawoof Sharief Muthuja Sherif Syncfusion Team May 16, 2018 05:26 AM UTC

Hi Thomas, 
 
Sorry for the inconvenience. 
 
We have created task for it. We will update it in the documentation and it will be included in our next release. 
 
Regards, 
Rawoof M. 
 


Loader.
Up arrow icon