Home > Class Reference > ENSLIB namespace > %Activate.Interface

%Activate.Interface

abstract class %Activate.Interface extends %Library.RegisteredObject

Property Inventory (Including Private)

Method Inventory (Including Private)

Properties (Including Private)

property %IDispatchPtr as %Integer [ Final ];
Property methods: %IDispatchPtrDisplayToLogical(), %IDispatchPtrGet(), %IDispatchPtrIsValid(), %IDispatchPtrLogicalToDisplay(), %IDispatchPtrNormalize(), %IDispatchPtrSet()

Methods (Including Private)

private method %CopyBack(ByRef pParam, pKnownType As %Integer, pValue, pActualType=$$$VTUNKNOWN, pOutputOnly=0, pBinary=0)
This method copies back the appropriate value for parameters passed by reference The knowntype is the type derived from the typelibrary, the actual type is the actual type of the variant returned from the invocation. The binary flag is used when binary streams are required to be returned rather than character streams
private method %FormatKnownParam(pParam, pFlags, pType) as %List
This method dynamically creates the appropriate parameter for passing to the underlying ActiveX implementation layer where the flags and types are known (proxy generated from typelibrary)
private method %FormatVariantParam(pParam) as %List
This method dynamically creates the appropriate parameter for passing to the underlying ActiveX implementation layer where the flags and types are not known in advance
method %GetRefCount() as %Integer
Return the current reference count on an ActiveX object
final method %IDispatchPtrSet(pIDispatchPtr As %Integer) as %Status
Set the internal 'handle'. If the handle references a a valid object, release that object first. Throw an exception If there is an ActiveX error during close
method %MakeVariantReturnValue(pResult As %List, pBinary As %Boolean = 0)
private final method %OnClose() as %Status
When the object is closed, the external ActiveX object must be closed also. Throw an exception if there is an ActiveX error during close
private method %OnNew(initval As %Integer) as %Status
When the object is created, the 'handle' to the external ActiveX object must be cached. It is this handle that is used to reference the external object for method invocation and property access.
final method Become(ClassName As %String) as %RegisteredObject

Become an instance of the named class by closing the current object and transferring the external objects' 'handle' to the new class. This method is used when you have an Instance of a generic object but you know what kind of Interface it expresses. For example, some properties or methods of ActiveX objects return a generic IDispatch handle but are documented as returning a more specific Interface derived from IDispatch. You can use this method to take advantage of that documented knowlege.

During the execution of this method a test is made to ensure that the external object really does support the requested interface. If not, an exception will be thrown

Inherited Members

Inherited Methods (Including Private)

Subclasses