INFO: Use ON_MESSAGE() Macro to Map Less-Common Messages (99848)
The information in this article applies to:
- The Microsoft Foundation Classes (MFC), when used with:
- Microsoft C/C++ for MS-DOS 7.0
- Microsoft Visual C++ for Windows, 16-bit edition 1.0
- Microsoft Visual C++ for Windows, 16-bit edition 1.5
- Microsoft Visual C++ for Windows, 16-bit edition 1.51
- Microsoft Visual C++ for Windows, 16-bit edition 1.52
- Microsoft Visual C++, 32-bit Editions 1.0
- Microsoft Visual C++, 32-bit Editions 2.0
- Microsoft Visual C++, 32-bit Editions 2.1
- Microsoft Visual C++, 32-bit Editions 4.0
- Microsoft Visual C++, 32-bit Editions 5.0
- Microsoft Visual C++, 32-bit Editions 6.0
- Microsoft Visual C++ .NET (2002)
This article was previously published under Q99848 SUMMARY
The Microsoft Foundation Class Library includes macros that an application
can include in the message map of a CWnd or CWnd derived object.These
macros, such as ON_WM_PAINT() and ON_WM_SIZE(), map common messages to
default handler functions. The Microsoft Foundation Class Library provides
macros for all standard window messages. To process user-defined message or
less-common window messages (like WM_COMMNOTIFY), use the ON_MESSAGE()
macro. The ON_MESSAGE macro must be used in a CWnd derived class. For
example, it cannot be used in a CWinApp class or a CDocument class because
neither of these classes is derived from CWnd.
Modification Type: | Major | Last Reviewed: | 12/11/2003 |
---|
Keywords: | kbArchitecture kbinfo KB99848 |
---|
|