The IOleObject interface (defined in oleidl.h) is the principal means by which the ActiveX designer communicates with its container. In most situations, an ActiveX designer's container is the same as its host, for example, Visual Basic. However, an ActiveX designer run-time object that is public can also be hosted by a web browser or web server.
Although the IOleObject interface contains 21 methods, ActiveX designers need not implement all of them; only those listed in the following table are required. The designer should return E_NOTIMPL for the methods it does not implement.
Method | Description |
Close | Changes the ActiveX designer from the running state to the loaded state. |
DoVerb | Invokes the ActiveX designer to perform one of its enumerated actions. |
GetClientSite | Retrieves the ActiveX designer's client site. |
GetMiscStatus | Returns OLE miscellaneous status flags for the ActiveX designer. |
SetClientSite | Informs the ActiveX designer of its client site in the container. |
SetHostNames | Informs the ActiveX designer of the names of its container application and container document. |
You may, however, implement any of the other methods your ActiveX designer requires for various other tasks. See the COM Programmer's Reference in the Platform Software Development Kit (SDK) for more information on IOleObject.