description | title | ms.date | f1_keywords | helpviewer_keywords | ms.assetid | |||
---|---|---|---|---|---|---|---|---|
Learn more about: Mapping Messages to Functions |
Mapping Messages to Functions |
09/06/2019 |
|
|
a7727a62-f638-4b20-b7f5-131f47200d6a |
The Class Wizard enables you to bind message handlers (member functions of MFC user-interface classes) to the messages generated by your application's resources. They use MFC message maps to create the binding.
When you use Class View to create a new class derived from one of the framework classes, it automatically places a complete and functional class in the header (.h) and implementation (.cpp) files that you specify.
Note
To add a new class that does not handle messages, create the class directly in the text editor.
-
In Class View, right-click the class.
-
In the context menu, choose Class Wizard.
MFC Message Handler
Adding Functionality with Code Wizards
Adding a Class
Adding a Member Function
Adding a Member Variable
Overriding a Virtual Function
Navigating the Class Structure