Here it works great for me ....
Private Sub DataGridView1_KeyDown(sender As Object, e As System.Windows.Forms.KeyEventArgs) Handles DataGridView1.KeyDown 'Lets see what keys we have down shall we?' If My.Computer.Keyboard.ShiftKeyDown And e.KeyCode = Keys.Space Then DataGridView1.CurrentCell.Selected = False End If End Sub
Here is another way.
Private Sub DataGridView1_KeyDown(sender As Object, e As System.Windows.Forms.KeyEventArgs) Handles DataGridView1.KeyDown 'Lets see what keys we have down shall we?' If My.Computer.Keyboard.ShiftKeyDown And e.KeyCode = Keys.Space Then 'SendKeys.Send(Keys.Space) DataGridView1.CurrentCell.Selected = False End If End Sub
Just experiment with them, and I hope something works for you?
source share