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

Issue of RadGridView Binding to a ListCollectionView with same parent type but multiple children types

3 Answers 150 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Stephen Zeng
Top achievements
Rank 1
Stephen Zeng asked on 20 Jun 2011, 02:23 AM
Hi Admin,

I did some search in this forum and it seemed that no similar topic has been post.

I have an ObservableCollection<AbstractEntity> which contains some derived class instances such as CustomerEntity and EmployeeEntity. Binding this collection to a RadGridView ItemsSource is ok. Data is displayed correctly.

I want to apply some filters, such as showing CustomerEntity or EmployeeEntity only. So I defined a ListCollectionView like this:

var peopleCollectionView = (ListCollectionView)CollectionViewSource.GetDefaultView(this.People);

then bind the RadGridView ItemsSource to this ListCollectionView, and apply the filters to the ListCollectionView.

The filters work fine. But I found whenever there are multiple derived types of instances in the collection, the RadGridView shows the rows but the content in all the cells are empty. 

I checked the output and did not see any GUI exception.

Is it a known issue? Is there any solution for this?


Thanks,
Stephen




3 Answers, 1 is accepted

Sort by
0
Vlad
Telerik team
answered on 20 Jun 2011, 06:45 AM
Hello,

 Can you post more info about the grid version? Can you try also standard WPF DataGrid in this scenario?

Greetings,
Vlad
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
Stephen Zeng
Top achievements
Rank 1
answered on 20 Jun 2011, 06:57 AM
Hi Vlad,

The Telerik.Windows.Controls.GridView.dll version is 2011.1.315.35.

I have already tried the standard WPF control GridView in a ListView and it worked. It seems that it is a RadGridView issue when it binds to a ICollectionView and very easy to be reproduced as I described previously.

Thanks,
Stephen
0
Vlad
Telerik team
answered on 20 Jun 2011, 01:14 PM
Hi Stephen,

 The problem is identified and fixed immediately -  the fix will be part of our upcoming latest build later Today. I've added 2000 Telerik points to your account.

Kind regards,
Vlad
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
Tags
GridView
Asked by
Stephen Zeng
Top achievements
Rank 1
Answers by
Vlad
Telerik team
Stephen Zeng
Top achievements
Rank 1
Share this question
or