Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

CollectionViewSource in windows metro app

I have a collection, for which i require 3 different views
1. All data of collection
2. Grouped data (grouping criteria will be modified during application lifecycle )
3. Filtered data (filter criteria will be modified during application lifecycle)

What i want is that all views should bind to same collection so that any change to collection should be synced to all the views.

With WPF, this can be achieved using CollectionViewSource.
In Modern UI apps, CollectionViewSource still exists, but with limited capabilities. It does not have SortDescription and FilterDescription.

How to achieve collection sync in Modern UI apps?

like image 913
Tilak Avatar asked Nov 05 '22 00:11

Tilak


1 Answers

Apparently, you are asked to perform your sorting, grouping, and filtering with LINQ in WinRT. The CollectionViewSource appears to only provide a common view to be shared between controls.

Source

like image 117
Marc Avatar answered Nov 13 '22 05:11

Marc