This question is locked. New answers and comments are not allowed.
Hi,
I am using a RadGridView to show my items and it contains a GridViewSelectColumn. I do not want every item to be selectable (defined by a property within the item) so I listen to the SelectionChanging event of the RadGridView and cancel the SelectionChanging if an unselectable item is clicked.
Simiarly, I have override the GridViewSelectColumn's header with my own checkbox and listens to the Checkbox's click event to handle selecting only the items that are selectable when the header checkbox is clicked. I also adding a listener to the RadGridView's SelectionChanged event and check that if all selectable items are selected, then I set the header checkbox's IsChecked to true.
Here's the problem I am having. The header checkbox does not appear as checked when I click on it even though all selectable items are checked. Similarly, when I check all the selectable items one by one, when all items are checked the header checkbox does not appear as checked.
I have read that the checkbox may not appear as expected due to virtualization by default. Is there any way around this?
Is there a way to bind my DataItems (and the property I use as condition) with the state of the GridViewSelectColumn's header checkbox?
Thanks!
Chun
I am using a RadGridView to show my items and it contains a GridViewSelectColumn. I do not want every item to be selectable (defined by a property within the item) so I listen to the SelectionChanging event of the RadGridView and cancel the SelectionChanging if an unselectable item is clicked.
Simiarly, I have override the GridViewSelectColumn's header with my own checkbox and listens to the Checkbox's click event to handle selecting only the items that are selectable when the header checkbox is clicked. I also adding a listener to the RadGridView's SelectionChanged event and check that if all selectable items are selected, then I set the header checkbox's IsChecked to true.
Here's the problem I am having. The header checkbox does not appear as checked when I click on it even though all selectable items are checked. Similarly, when I check all the selectable items one by one, when all items are checked the header checkbox does not appear as checked.
I have read that the checkbox may not appear as expected due to virtualization by default. Is there any way around this?
Is there a way to bind my DataItems (and the property I use as condition) with the state of the GridViewSelectColumn's header checkbox?
Thanks!
Chun