Accessing the Keyboard (Visual Basic)
The My.Computer.Keyboard object provides properties for accessing the current state of the keyboard, such as what keys are currently pressed, and provides a method to send keystrokes to the active window.
This table lists tasks associated with the My.Computer.Keyboard object and points to topics demonstrating how to perform each task.
Determine whether CAPS LOCK is on
Determine whether the SHIFT key is down
Determine whether the ALT key is down
Determine whether the CTRL key is down
Determine whether NUM LOCK is on
Determine whether SCROLL LOCK is on
Start an application and send it keystrokes