The Microsoft Foundation Class Library can be divided into two major sections: (1) the MFC classes and (2) macros and globals. If a function or variable is not a member of a class, it is a global function or variable.
The MFC library and the Active Template library (ATL) share string conversion macros. See String Conversion Macros in the ATL documentation for a discussion of these macros.
The MFC macros and globals offer functionality in the following categories:
General MFC
Database
Internet
OLE
In addition, MFC provides a function, called AfxEnableControlContainer, that enables any OLE container, developed with MFC 4.0, to fully support embedded OLE controls.
OLE Controls
The first part of this section briefly discusses each of the above categories and lists each global and macro in the category, along with a brief description of what it does. Following this — in alphabetical order — are complete descriptions of the global functions, global variables, and macros in the MFC library.
The main supporting reference for the MFC Macros and Globals section is Visual C++ Programmer's Guide. This is usually the first place you should look to find more information on macros and globals. When necessary, the appropriate article in Visual C++ Programmer's Guide is mentioned with the function or macro description.
Note Many global functions start with the prefix "Afx" — but some, such as the dialog data exchange (DDX) functions and many of the database functions, deviate from this convention. All global variables start with "afx" as a prefix. Macros do not start with any particular prefix, but they are written all in uppercase.