I love WPF

"jamais sans son interface"

I love WPF

"jamais sans son interface"

TreeView

Alternative for ICollectionView (for sorting update)

When you want to sort a collection in MVVM you use ICollectionView view = CollectionViewSource.GetDefaultView(Items); view.SortDescriptions.Clear(); view.SortDescriptions.Add(new SortDescription(« DirtyName », ListSortDirection.Descending)); but if you want to update sorting in treeview for sample you can use ListCollectionView view = new ListCollectionView(collection); view.IsLiveSorting = true; SortDescription sort = new SortDescription(« DirtyName », ListSortDirection.Ascending); view.SortDescriptions.Add(sort); and set IsLiveSorting to true for sample […]

Retour en haut