How do i detect if the delete key has been pressed?
Printable View
How do i detect if the delete key has been pressed?
if you have it on KeyDown event, you can do the following:
VB Code:
If e.KeyCode = Keys.Delete Then ' Delete Key was pressed End If
Where do you wish to detect this? Kevin's code should work, you may need to change the keypreview property to true on the form...