I have a GridDataBoundGrid. I want to setup a hotkey similar to Excel''s that allows a user to select the entire row of the current cell by typing (Shift + Spacebar).
I have tried every key event I can find (KeyUp, KeyDown, KeyPress, CurrentCellKeyUp, etc..) In every case, I can get it to select the entire row..
BUT.. I cannot seem to prevent the keyboard event from also activating the current cell and typing a space into it. The e.Handled part seems to have no effect (I believe it may be because the space has already been typed into the active cell by the time I get the message)
So how can I trap the (Shift + Spacebar) key event and prevent it from also typing into the active cell?
Here is 1 way I have unsucessfully tried to do this:
private void gridDataBoundGrid1_KeyDown(object sender, System.Windows.Forms.KeyEventArgs e)
{
if (e.KeyCode == Keys.Space && e.Shift == true)
{
// do my stuff here to select the row...
e.Handled = true;
}
}
Thanks,
Brian