OLE Control Containers Must Call AfxEnableControlContainerLast reviewed: February 17, 1998Article ID: Q150029 |
The information in this article applies to:
- Microsoft Visual C++, 32-bit Edition, versions 4.0, 4.1, 5.0
SUMMARYUsing Visual C++ version 4.0, it is possible to construct OLE Control Containers. These containers must call AfxEnableControlContainer() in their CWinApp::InitInstance(). This call is added automatically if OLE Controls support is checked in AppWizard Step 3, but in some cases, this call must be added manually. This article explains why you need to call AfxEnableControlContainer() and the possible problems that might occur if this call is not made.
MORE INFORMATIONAfxEnableControlContainer() is responsible for wiring up the support structure necessary for a CWnd object to contain an OLE Control. This call is added to a project by AppWizard if OLE Controls support is selected. You need to add this call manually in the following cases:
The following list outlines some of the most common problems (others are possible) that can occur if AfxEnableControlContainer() is not called:
Keywords : CDKIss MfcOLE VCx86 Technology : kbole kbMfc Version : Winnet:4.0,4.1,5.0 Platform : NT WINDOWS |
================================================================================
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |