This is a migrated thread and some comments may be shown as answers.

[Solved] When row and column virtualization is true, data bindings not maintained on DetailsVisibilityProperty

1 Answer 61 Views
GridView
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
J
Top achievements
Rank 1
J asked on 28 Oct 2011, 09:30 PM
I have a RadGridView whose DetailsVisibility is bound to the IsChecked value of a ToggleButton.

private void Init()
{
    var toggleBinding = new Binding("IsChecked") {
        Source = this.toggleButton,
        Mode = BindingMode.TwoWay,
        Converter = new BooleanToVisibilityConverter()
    };
 
    this.parentRow.SetBinding(GridViewRow.DetailsVisibilityProperty, toggleBinding);
}

Where this.toggleButton is of type Primitives.ToggleButton and this.parentRow is of type Telerik. ... .GridViewRow. The RadGridView is horizontally scrollable and when I check the ToggleButton, making the details visible, then scroll such that the ToggleButton is not viewable, the row details automatically collapses. The cell values maintain their binding when I scroll such that the cells do not clear when I scroll away and scroll back, but the toggle button does not. This is obviously an issue because I do not want the row details to collapse when scrolling.

Is there a workaround or can this be addressed? Thanks.

1 Answer, 1 is accepted

Sort by
0
Rossen Hristov
Telerik team
answered on 31 Oct 2011, 12:59 PM
Hello J,

We have a special column called GridViewToggleRowDetailsColumn which will maintain state even with virtualization turned on. If you decide to use a custom approach for this then I am afraid that it would be up to you to maintain that state.

Best wishes,
Ross
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

Tags
GridView
Asked by
J
Top achievements
Rank 1
Answers by
Rossen Hristov
Telerik team
Share this question
or