An application can create messages to use in its own windows. If an application does create messages, the window procedure that receives the messages must interpret them and provide the appropriate processing.
The operating system reserves the message-identifier values in the range 0x0000 through 0x0FFF (the value of WM_USER - 1) for system-defined messages. Applications cannot use these values for their private messages.
In addition, the operating system uses certain message values higher than WM_USER. Applications should not use these message values. A partial listing of these messages is in the following figure:
From PMSTDDLG.H: #define FDM_FILTER WM_USER+40 #define FDM_VALIDATE WM_USER+41 #define FDM_ERROR WM_USER+42 #define FNTM_FACENAMECHANGED WM_USER+50 #define FNTM_POINTSIZECHANGED WM_USER+51 #define FNTM_STYLECHANGED WM_USER+52 #define FNTM_COLORCHANGED WM_USER+53 #define FNTM_UPDATEPREVIEW WM_USER+54 #define FNTM_FILTERLIST WM_USER+55
You should scan your header files to see if other messages have been defined with values higher than WM_USER.
Aside from the message values used by the operating system, values in the range 0x1000 (the value of WM_USER) through 0xBFFF are available for message identifiers, defined by an application, for use in that application.
Warning: It is very important that applications do not broadcast messages in the 0x1000 through 0xBFFF range due to the risk of misinterpretation by other applications.
Values in the range 0xC000 through 0xFFFF are reserved for message identifiers that an application defines and registers with the system atom table; these can be used in any application. Values above 0xFFFF (0x00010000 through 0xFFFFFFFF) are reserved for future use; applications must not use messages in this range.