ActiveX Control Naming Scheme

When you incorporate an ActiveX control into an IDL widget hierarchy using the WIDGET_ACTIVEX routine, IDL automatically creates an IDLcomActiveX object that instantiates the control and handles all communication between it and IDL. You tell IDL which ActiveX control to instantiate by passing the COM class or program ID for the ActiveX control to the WIDGET_ACTIVEX routine as a parameter.

IDL automatically creates a dynamic subclass of the IDLcomActiveX class (which is itself a subclass of the IDLcomIDispatch class) to contain the ActiveX control. The resulting class name looks like

IDLcomActiveX$ID_type$ID 

where ID_type is one of the following:

and ID is the COM object's actual class or program identifier string.

For more on COM class and program IDs see Class Identifiers and Program Identifiers.

While you will never need to use this dynamic class name directly, you may see it reported by IDL via the HELP routine or in error messages. Note that when IDL reports the name of the dynamic subclass, it will replace the hyphen characters in a class ID and the dot characters in a program ID with underscore characters. This is because neither the hyphen nor the dot character are valid in IDL object names.

Finding COM Class and Program IDs

In general, if you wish to incorporate an ActiveX object into an IDL widget hierarchy, you will know the COM class or program ID, either because you created the control yourself or because the developer of the control provided you with the information.

If you do now know the class or program ID for the COM object you want to use, you may be able to determine them using the OLE/COM Object Viewer application provided by Microsoft. For more information, see Finding COM Class and Program IDs.