There are many system-defined messages that are used to control the operations of applications and to provide input and other information for applications to process. The system sends or posts a system-defined message when it communicates with an application. An application also can send or post system-defined messages. Usually, applications use these messages to control the operation of control windows created by using preregistered window classes.
Each system message has a unique message identifier and a corresponding symbolic constant. The symbolic constant, defined in the system header files, states the purpose of the message. For example, the WM_PAINT constant represents the paint message, which requests that a window paint its contents.
The symbolic constants also specify the message category. System-defined messages can belong to several categories; the prefix identifies the type of window that can interpret and process the messages. The following table lists the prefixes and their related message categories:
┌───────────────┬─────────────────────────────────────────────┐ │Prefix │Message category │ ├───────────────┼─────────────────────────────────────────────┤ │BKM_ │Notebook control │ ├───────────────┼─────────────────────────────────────────────┤ │BM_ │Button control │ ├───────────────┼─────────────────────────────────────────────┤ │CBM_ │Combination-box control │ ├───────────────┼─────────────────────────────────────────────┤ │CM_ │Container control │ ├───────────────┼─────────────────────────────────────────────┤ │EM_ │Entry-field control │ ├───────────────┼─────────────────────────────────────────────┤ │LM_ │List-box control │ ├───────────────┼─────────────────────────────────────────────┤ │MLM_ │Multiple-line entry field control │ ├───────────────┼─────────────────────────────────────────────┤ │MM_ │Menu control │ ├───────────────┼─────────────────────────────────────────────┤ │SBM_ │Scroll-bar control │ ├───────────────┼─────────────────────────────────────────────┤ │SLM_ │Slider control │ ├───────────────┼─────────────────────────────────────────────┤ │SM_ │Static control │ ├───────────────┼─────────────────────────────────────────────┤ │TBM_ │Title-bar control │ ├───────────────┼─────────────────────────────────────────────┤ │VM_ │Value set control │ ├───────────────┼─────────────────────────────────────────────┤ │WM_ │General window │ └───────────────┴─────────────────────────────────────────────┘
General window messages cover a wide range of information and requests, including: