This question is locked. New answers and comments are not allowed.
I'm constantly getting an error when programmatically changing the selecteditems property of my grid
"Cannot change ObservableCollection during a CollectionChanged or PropertyChanged event."
(with builds 1110 and 1119 latest Q3 hotfix)
"Cannot change ObservableCollection during a CollectionChanged or PropertyChanged event."
(with builds 1110 and 1119 latest Q3 hotfix)
foreach(CustomerItem csItem in csList.Where(csi=> csi.IsActive == true)) { if (GridRubrieken.Items.Contains(csItem)) GridRubrieken.SelectedItems.Add(csItem); } I've tried to use a Dispatcher, "Dispatcher.BeginInvoke(new Action(() => .. etc..", without success
i'm trying to change the selecteditems property from a listbox > selectionchanged event. In which the user can make a selection, i'm then applying a selection, based on the IsActive setting.
There doesn't seem to be anything wrong with my code on first sight, it actually does work -sometimes...
Any ideas, we're trying to get our demo done, and getting ready to become your customer!
-edit: last thing i would like to mention, the grid is bound to a simple List or ObservableCollection, nothing fancy in this case.