Completed
Last Updated: 13 Oct 2015 08:25 by ADMIN
ADMIN
Dess | Tech Support Engineer, Sr.
Created on: 23 Feb 2015 15:41
Category: GridView
Type: Bug Report
0
FIX. RadGridView - filtered row is still selected when clearing the applied filter
To reproduce:
 this.radGridView1.MultiSelect = true;

Please refer to the attached gif file illustrating better the behavior.

1. Select a row and filter the grid in a way to keep the selected row visible.
2. The first row in the ChildRows collection is selected.
3. Clear the filter. The selection is stored and only one row is selected.
4. Repeat the above steps, but perform such filtering that hides the selected cell. When you clear the filter, two rows are selected instead of one.

Workaround:
private void radGridView1_FilterChanged(object sender, Telerik.WinControls.UI.GridViewCollectionChangedEventArgs e)
        {
            this.radGridView1.ClearSelection();
            if (this.radGridView1.CurrentCell!=null)
            {
                this.radGridView1.CurrentCell.IsSelected = true;
                this.radGridView1.CurrentRow.IsSelected = true;
                this.radGridView1.GridNavigator.Select(this.radGridView1.CurrentRow, this.radGridView1.CurrentColumn);
            }
        }
0 comments