Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All
Important This document may not represent best practices for current development, links to downloads and other resources may no longer be valid. Current recommended version can be found here.

Class Factories and Licensing

To create an instance of your OLE control, a container application calls a member function of the control's class factory. Because your control is an actual OLE object, the class factory is responsible for creating instances of your control. Every OLE control class must have a class factory.

Another important feature of OLE controls is their ability to enforce a license. ControlWizard allows you to incorporate licensing during the creation of your control project. For more information on control licensing, see the article ActiveX Controls: Licensing An ActiveX Control.

The following table lists several macros and functions used to declare and implement your control's class factory and to license of your control.

Class Factories and Licensing


Declares the class factory for an OLE control or property page.


Implements the control's GetClassID function and declares an instance of the class factory.


Begins the declaration of any licensing functions.


Ends the declaration of any licensing functions.


Verifies whether a control is licensed for use on a particular computer.

Community Additions

© 2015 Microsoft