Reset GridView Column Filter When RadGridView Data is Reloaded
Environment
Product Version | 2024.4.1213 |
Product | RadGridView for WPF |
Description
How to remove the column filter when the ItemsSource of RadGridView is reset.
Solution
By default the column filter is not cleared when the ItemsSource of RadGridView gets updated. To do this, manually clear the ColumnFilterDescriptor of the GridViewDataColumn objects.
foreach (var column in gridView.Columns.OfType<GridViewDataColumn>())
{
column.ColumnFilterDescriptor.Clear();
}