The goal of this article is to show how to get the filtered items from a GridView (here we will use Telerik RadGridView, but it should be the same for any Grid).

This case is really useful if you need to apply some calculation on a filtered subset of the Data you’re displaying, while you’re still having access to the full collection for other calculations.

 The View:

The code-behind:

The View-Model:

BindableBase is part of the NuGet package Prism.MVVM. It’s simply an implementation of INotifyPropertyChanged.

The concept is to get a “View” of the represented Data on screen.

So as you can see in this code, ICollectionView (System.ComponentModel which could be a ListCollectionView for example) should work with any Grid, but it seems that the Telerik controls can have some issues. But they work perfectly with a QueryableCollectionView (from Telerik.Windows.Data). 

Happy coding!