Sorting Expressions
Overview
The SortDescriptors collection exposes the Expression property which is used to create flexible sorting conditions. Expression is a string that contains the column name followed by "ASC" (ascending) or "DESC" (descending). The columns are sorted ascending by default. Multiple columns can be separated by commas.
Creating expressions
Creating a simple expression:
Creating simple sorting expression
Sorting by two columns using expressions: