The information in this article applies to:
SUMMARY
In the Microsoft Windows environment, an application can define a private
message for its own use without calling the RegisterWindowMessage API.
Message numbers between 0x8000 and 0xBFFF are reserved for this purpose.
MORE INFORMATION
The WM_APP constant is used by applications to help define private message, usually of the from WM_APP + X, where X is an integer value.
The documentation for the WM_USER message lists four ranges of message
numbers as follows:
When an application subclasses a predefined Windows control or
provides a special message in its dialog box procedure, it cannot use
a WM_USER+x message to define a new message because the predefined
controls use some WM_USER+x messages internally. It was necessary to
use the RegisterWindowMessage function to retrieve a unique message
number between 0xC000 and 0xFFFF.
To avoid this inconvenience, messages between 0x8000 and 0xBFFF were redefined to make them available to an application. Messages in this range do not conflict with any other messages in the system. The distinction here is that WM_USER messages are specific to a window class (whether it is a control or a user-defined class), while WM_APP messages are not. While WM_USER messages can be treated as application messages, the danger in doing so is that if any are already pre-defined for a particular window class, they could be misinterpreted upon receipt. Additional query words:
Keywords : kbNTOS kbGrpUser kbWinOS kbWndw kbWndwMsg |
Last Reviewed: February 3, 2000 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |