DoVerb
PowerScript function
Description
Requests the OLE server application to execute the specified verb
for the OLE object in an OLE control or OLE DWObject.
Applies to
OLE controls and OLE DWObjects (objects within a DataWindow object
that is within a DataWindow control)
Syntax
|
1 |
objectref.DoVerb ( verb ) |
|
Argument |
Description |
||
|---|---|---|---|
|
objectref |
The name of the OLE control or the fully qualified name of
|
||
|
verb |
An integer identifying a verb known to the OLE server |
Return value
Integer.
Returns 0 if it succeeds and one of the following values if an error
occurs:
-1 — Container is empty
-2 — Invalid verb for object
-3 — Verb not implemented by object
-4 — No verbs supported by object
-5 — Object cannot execute verb now
-9 — Other error
If any argument’s value is null, DoVerb returns null.
Examples
This example executes verb 7 for the object in the OLE control
ole_1:
|
1 2 |
integer result result = ole_1.DoVerb(7) |
This example executes verb 7 for the object in the OLE DWObject
ole_graph:
|
1 2 |
integer result result = dw_1.Object.ole_graph.DoVerb(7) |
See also
OLEActivate method for DataWindows in the section called “OLEActivate” in DataWindow Reference.