Keyboard Input - Visual Basic

Hi,

I want to use Keyboard Input in Visual Basic, to perform operations such as rotate a cube, I want to use the key “R” on the keyboard to do that.

Can anybody help?

Thanks

Bhaji

its been a while since i used vb but i think this will work:

Private Sub Form_KeyDown(KeyCode As Integer, Shift As Integer)

If KeyCode = vbKeyR Then
do_somthing
End If

End Sub