Skip to main content Skip to footer

A WinRT CollectionView class with Filtering and Sorting

Data filtering and sorting are important features of .NET since it was introduced over 10 years ago. The DataTable class has supported both since .NET 1.0. When WPF came along, it introduced the ICollectionView interface, which in addition to sorting and filtering supports grouping and currency (the notion of a current item). Surprisingly, the ICollectionView interface specified in the WinRT version of the system libraries does not support sorting, filtering, or grouping. In WinRT, you can show a list of items on a grid, but there is no standard method for sorting or filtering this data. This article describes ICollectionViewEx, an extended version of the ICollectionView interface and the implementation of a ListCollectionView class that implements it. With this class, you can add sorting and filtering to your data the same way you do it in your WPF, Silverlight, and Windows Phone applications. ICollectionViewEx is the basis of the new IC1CollectionView interface and C1CollectionView class included in Studio for WinRT XAML. Read the full article on codeproject.

MESCIUS inc.

comments powered by Disqus