Hi, I've a grid witch is binded with a datasource. I've a boolean column witch is checked when the user press space key. To do that, I use the grid.selected.Rows.
When I press space on a multiple selection, the activeRow is in the grid.seleted.Rows
and When I Press the space key another time, the activeRow isn't selected and isn't in grid.seleted.Rows
Because of that, when I check the boolean column, I've to test if the activeRow is selected or not to not forgive it :
If I don't modify the boolean column (the grid doesn't enter in edit mode), the grid reacts in the same way.
Could I know why the componant react like that ?
Hi,
I call the method with the keyDown and a clickevent on two menuItems.
With the Handled = true, the activeRow stay seleted.
Thanks.
By default, the SpaceBar is mapped to selected/unselect a row. From what event are you calling the code you posted here?
If you are handling one of the grid's Key events, like KeyDown and you are handling the SpaceBar to change the checked state of your boolean column, then you probably just need to set e.Handled to true to indicate that you handled the keystroke and the grid should not handle it again after you.