I am not sure this is related to my previous issue http://es.infragistics.com/community/forums/p/82953/414626.aspx#414626
but i get the same exception if the underlying source is shared between two grids via collectionview. Please see attached.
To fix this remove the following lines from gridview.xaml.cs
grid.FilteringSettings.AllowFiltering = FilterUIType.FilterMenu; grid.FilteringSettings.FilteringScope = FilteringScope.ColumnLayout;
Much appreciate if you could please take this with your development team on a high priority if possible?
Thanks,
Rohit
Sample attached
This surely is a bug in your library. Seems there is an initialization issue, the way i fixed is by checking the collectionchange notification (See attached)
private void DeferAddFilterRow() { if (!DataSource.View.IsEmpty) { AddFilterRow(); return; } DataSource.View.CollectionChanged += DataSourceViewCollectionChanged; }
private void DataSourceViewCollectionChanged(object sender, NotifyCollectionChangedEventArgs e) { if (!DataSource.View.IsEmpty) { DataSource.View.CollectionChanged -= DataSourceViewCollectionChanged; App.Current.Dispatcher.BeginInvoke(new Action(AddFilterRow)); } }
private void AddFilterRow() { grid.FilteringSettings.AllowFiltering = FilterUIType.FilterMenu; grid.FilteringSettings.FilteringScope = FilteringScope.ColumnLayout; }
private CollectionViewSource dataSource; public CollectionViewSource DataSource { get { return dataSource; } set { dataSource = value; var binding = new Binding { Source = value }; BindingOperations.SetBinding(grid, XamGrid.ItemsSourceProperty, binding); DeferAddFilterRow(); } }
Hello Rohit,
Development issue
14806: Populating empty IEditableCollectionView causes exception when FilterRow is enabled
has been verified by test team and will be released in the next service release.
You will be automatically notified when this is released via the private case CAS-121066-B5D6C5 associated with you initial forum thread (http://es.infragistics.com/community/forums/p/82953/414626.aspx#414626).
Please let me know if you have any questions.
Sincerely,
Valerie
Developer Support Supervisor - XAML
Infragistics
www.infragistics.com/support
HI,
This developer issue has been addressed and it's being tested now.
Here a link to our Service Release Schedule:
http://es.infragistics.com/help/service-releases/
Hi Yanko,
Sorry but didn't understand what do you mean by "checking your progress"r? This is a showstopper and a bug in your library so i had to remove observable collection since xamgrid does not play nice with observable collection (wasted my week of efforts).
I am just checking your progress on the issue.
If you require any further assistance please do not hesitate to ask.
I have been looking into your posts and the explained issue is the same referred in the forum thread where you had discussed it with Matt. Currently our development team is working on it.
Let me know, if you need any other questions on this matter.