For an ActiveX control to support such event handling, it must implement the IProvideClassInfo or IProvideClassInfo2 interface. Internet Explorer queries the control for these interfaces and, if implemented, calls the GetClassInfo() method to obtain the type library for the control. Internet Explorer will initially query the control for IProvideClassInfo2 and, if this is not implemented, will then query for IProvideClassInfo.
The IProvideClassInfo2 interface is derived from IProvideClassInfo and provides an additional method, GetGUID(), which returns an object's outgoing interface ID for it's default event set.
For ActiveX controls developed using the Microsoft Foundation Classes, the IProvideClassInfo2 interface is implemented by default.
For ActiveX controls developed using Microsoft Visual Basic, the IProvideClassInfo interface is implemented by default.
When using the Microsoft Active Template Library (ATL), version 3.0, the following 'lite control' ATL objects do not implement the IProvideClassInfo2 interface by default:
- Simple Object
- Internet Explorer Object
- Lite Control
- Lite Composite Control
- Lite HTML Control
- Add the following line to your class derivation list:
public IProvideClassInfo2Impl<&CLSID_<object_name>, NULL,
- Add the following lines to your COM_MAP:
For more information about developing Web-based solutions for Microsoft Internet Explorer, visit the following Microsoft Web sites:(c) Microsoft Corporation 1999, All Rights Reserved. Contributions by Mark Davis, Microsoft Corporation.
Article ID: 200839 - Last Review: May 11, 2006 - Revision: 1