Method ActiveXObject():isEventSubscribed() Foundation
Determines whether a COM/ActiveX event has been subscribed to.
:isEventSubscribed( <cName> | <nDISPID> ) --> lReturn
:isEventSubscribed() returns a logical value. If the class implements event handling of any kind for the COM/ActiveX event specified, :isEventSubscribed() returns the value .T. (true). If no event handler is defined for processing the event, the method returns .F. (false).
Method :isEventSubscribed() can be used by an application to determine whether the ActiveXObject is ready to process a specific COM/ActiveX event.
If a value greater zero is returned by :isEventSubscribed(), the COM/ActiveX event has been subscribed and can be handled by the object. Event handling logic can be provided either through the methods implemented by a class derived from ActiveXObject, or via a code block assigned to the corresponding instance variable (callback slot).
A COM/ActiveX event can be subscribed to either by the class designer or at the application level. In the former case, the designer of a class derived from ActiveXObject implements a method that has the same name as a COM/ActiveX event. The framework automatically calls this method when the corresponding COM/ActiveX event is fired by the ActiveX object connected. The method implicitly becomes the default event handler for the event. In order to implement event handling on the application level, a callback code block must be assigned to the event's callback slot (instance variable). ActiveXObject also provides the method :subscribeEvent()which offers a low-level interface for binding logic to a certain COM/ActiveX event.
If either of these approaches is used, the COM/ActiveX event is subscribed to by the ActiveObject instance and method :isEventSubscribed()returns the value .T. (true).
If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.