Sorting databound items

Hello,
is there a way to setup a sorting on databound TreeViewAdv items? I've tried to use Sorting and SortingField properties and it seems to have no effect.

Regards
Ondřej Svoboda

1 Reply

VR Vijayalakshmi Roopkumar Syncfusion Team April 24, 2018 06:34 AM UTC

Hi Ondrej

Thank you for contacting Syncfusion Support.

In our TreeViewAdv, we can able to Sort the TreeViewItems using Sorting enum property of type SortDirection which has the following values such as Ascending, Descending and None. You can use this property to sort according to the desired direction. Also the SortingField is the property which is used to sort the items in different SortDirection based on sorting criteria. However it would not work for DataBound items.

A sample has been prepared for the same using the Sorting property for your reference and it can be download from the following location:

Samplehttp://www.syncfusion.com/downloads/support/forum/137182/ze/TreeViewAdv_Itemsourcesorting-1261245716 

Kindly try this solution and let us know if it is helpful.

Regards
Vijayalakshmi V.R. 


Loader.
Up arrow icon