Unhandled exception System.InvalidOperationException: The calling thread cannot access this object because a different thread owns it. at System.Windows.Threading.Dispatcher.VerifyAccess() at System.Windows.DependencyObject.GetValue(DependencyProperty dp) at Telerik.Windows.Data.SortDescriptorBase.get_SortDirection() at Telerik.Windows.Data.Expressions.SortDescriptorCollectionExpressionBuilder.Sort() at Telerik.Windows.Data.QueryableExtensions.Sort(IQueryable source, IEnumerable`1 sortDescriptors) at Telerik.Windows.Data.QueryableExtensions.Sort(IQueryable source, SortDescriptorCollection sortDescriptors) . . .
This behavior is reproducible when the SelectionUnit property of the RadGridView is set to "FullRow". SelectedCells collection is not of the selected row updated when new columns are added runtime. For example, you have selected the first row which has 3 cells. Then you add 2 new columns. Now the row has 5 cells but the selected cells collection still have 3. A possible workaround which can be used is to reset the SelectedItem property of the RadGridView. var selectedItem = testGrid.SelectedItem; testGrid.SelectedItem = null; this.testGrid.Columns.Add(new GridViewDataColumn() { Header = "Value3", DataMemberBinding = new Binding("Value3"), Width = 100 }); this.testGrid.Columns.Add(CreateColumn("Value4", "Value4")); testGrid.SelectedItem = selectedItem;
To reproduce this:
Change the Default Selected Filter Operator:
https://docs.telerik.com/devtools/wpf/controls/radgridview/filtering/how-to/howto-change-the-default-selected-filter-operator
This doesn't work for boolean columns, if the property "ShouldGenerateFieldFilterEditors" of the column is set to "True".
Please see the attached example.
*** The fix for this issue will be available with the next LIB (version 2018.3.1217) expected on Monday, December 17.