Sorting in WPF (Data grid from WPF Toolkit), CSLA 3.6

Sorting in WPF (Data grid from WPF Toolkit), CSLA 3.6

Old forum URL: forums.lhotka.net/forums/t/6003.aspx


maxal posted on Tuesday, December 16, 2008

Hello,

I am trying to use sorting using DataGrid from WPF Toolkit. First, I tried this approach in creating list (sourceList is ReadOnlyBaseList):

Transactions = new SortedBindingList<BatchSummary>(sourceList);

It didn't work. Then I tried Linq:

Transactions = from summary in sourceList select summary;

Now sorting works, but I have some questions:

1. Why SortedBindingList didn't work?
2. What is the right way to do it in 3.6?
3. There is some support for sorting now with indexes. How to use it?

I really want to archive this utilizing bult-in functionality from DataGrid.

Thank you.

Copyright (c) Marimer LLC