Arbortext Command Language > Functions by Alphabetical Listing > com_call
  
com_call
result = com_call (handle, intname[, arg1[, argn]])
Invokes a method in a COM object previously attached to using com_attach or one returned by a method called previously.
The handle parameter is a handle returned by a call to com_attach or returned by a previous call to a COM method or property.
The intname parameter is a character string that gives the name of the method to be invoked.
All other parameters (if any) are passed to the method named by intname in the object specified by the object's handle. Each parameter will be converted to the type expected by the interface being invoked.
The return value will be converted to an appropriate ACL type before being used. If it is a COM interface, it will be converted into a handle to the interface which can be used in subsequent calls to com_call. The handle must be released using com_release when it is no longer needed.
Example
result = com_call(wordh, "Quit", -1)
invokes the Quit method in the COM object represented by wordh. If this is the handle returned by the example in com_attach, this will cause Microsoft Word to quit while saving open documents. The other two optional parameters to the Quit method are omitted.
* 
In COM interfaces, “True” is represented by minus one (-1) and “False” by zero (0).
Related Topics
com_attach function
com_prop_get function
com_prop_put function
com_release function