This is a migrated thread and some comments may be shown as answers.

Why is grid's CollectionView private?

2 Answers 58 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Dan
Top achievements
Rank 1
Dan asked on 14 Sep 2010, 07:22 PM
I have a business requirement to render on a map control the same data that is displayed in a GridView control.  For example, if the grid is loaded with all of the companies locations in North America, display those locations on the map.  That part is simple.  Where I have a problem is if the user filters the grid to show only US locations, they want the map to show only those locations. 

I can see that the RadGridView.Items class has a private property of CollectionView that contains the collection of the filtered items. if this collectionview were a read-only property I could just use if for my map object.

I would think that reusing the filtered data from a grid for other purposes would not be an entirely rare requirement.

Is there another way to do this that I am missing?

Thanks in advance for any assistance.

2 Answers, 1 is accepted

Sort by
0
Milan
Telerik team
answered on 17 Sep 2010, 07:33 AM
Hi Dan,

The state of the grid is reflected in its Items property - if you filter the grid only the items that pass the filters will be listed in Items. Have you tried using this collection as a source for the map?


All the best,
Milan
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Dan
Top achievements
Rank 1
answered on 20 Sep 2010, 02:40 PM
Hi Milan, the Items property is what I needed.  Thanks for the help.
Tags
GridView
Asked by
Dan
Top achievements
Rank 1
Answers by
Milan
Telerik team
Dan
Top achievements
Rank 1
Share this question
or