问题
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?
回答1:
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
来源:https://stackoverflow.com/questions/10582919/collectionviewsource-in-windows-metro-app