WM_INPUT message

Sent to the window that is getting raw input.

A window receives this message through its WindowProc function.

#define WM_INPUT 0x00FF

Parameters

wParam

The input code. Use GET_RAWINPUT_CODE_WPARAM macro to get the value.

Can be one of the following values:

Value Meaning
RIM_INPUT
0
Input occurred while the application was in the foreground.
The application must call DefWindowProc so the system can perform cleanup.
RIM_INPUTSINK
1
Input occurred while the application was not in the foreground.

lParam

A HRAWINPUT handle to the RAWINPUT structure that contains the raw input from the device. To get the raw data, use this handle in the call to GetRawInputData.

Return value

If an application processes this message, it should return zero.

Remarks

Raw input is available only when the application calls RegisterRawInputDevices with valid device specifications.

Requirements

Minimum supported client Windows XP [desktop apps only]
Minimum supported server Windows Server 2003 [desktop apps only]
Header
Winuser.h (include Windows.h)

See also

Reference

GetRawInputData

RegisterRawInputDevices

RAWINPUT

GET_RAWINPUT_CODE_WPARAM

Conceptual

Raw Input