Method ActiveXObject():resumeEvent() Foundation

Resumes event processing for a COM/ActiveX event.

Syntax
:resumeEvent( <cName> | <nDISPID> | NIL ) --> nSuspendCount
Parameters
<cName>
<cName> is a character string with the name of the event processing is to be resumed for.
<nDISPID>
<nDISPID> is a numeric value that specifies the dispatch ID (DISPID) of the event processing is to be resumed for. This parameter may be used as an alternative to parameter <cName>.
NIL
If the value NIL is passed to :resumeEvent(), event processing is resumed for all COM/ActiveX events subscribed by the ActiveX object.
Return

This method returns a numeric value specifying the current suspend count of the COM/ActiveX event or events specified. Processing for an event is suspended as long as the event's suspend count is greater than zero. If neither <cName> nor <nDISPID> are specified or NIL is passed as a parameter, return is the highest suspend count of the events subscribed by the ActiveXObject.

Description

The method :resumeEvent() can be used to resume event processing for a COM/ActiveX event previously suspended using method :suspendEvent(). If NIL is passed instead of an event name or dispatch ID (DISPID), event processing is resumed for all events subscribed by the ActiveX object.

Each call to method :resumeEvent() decrements a counter associated with the event or events specified. As long as an event's suspend counter contains a value greater than zero, the event remains suspended and no event processing is performed for the event by the ActiveXObject instance. Calling :resumeEvent() for an event that had already been resumed (i.e. whose suspend is already zero) has no effect.

An Xbase++ application can use the methods :resumeEvent() and :suspendEvent() to prevent recursive calls of a specific event handler code block or method. Furthermore, suspending events may be required when the application cannot respond to COM/ActiveX events for any reason.

Feedback

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.