Windows Input Messages

Whenever the user presses a key, moves the mouse, or clicks a mouse button, Windows responds by sending input messages to the appropriate application. Windows also sends input messages in response to timer input.

Windows provides several types of input messages:

Message Description

Keyboard User input through the keyboard
Character Keyboard input translated into character codes
Mouse User input through the mouse
Timer Input from the system timer
Scroll-bar User input through a window's scroll bars and the mouse
Menu User input through a window's menus and the mouse

The keyboard, mouse, and timer input messages correspond directly to hardware input. Windows passes these messages to your application through the application queue.

The character, menu, and scroll-bar messages are created in response to mouse and keyboard actions in the nonclient area of a window, or are the result of translated keyboard messages. Normally, Windows sends these messages directly to the appropriate window function.