of_clickButton

Description

Causes a button to be clicked programmatically, without user intervention.

Syntax

of_clickButton(Long button)
of_clickButton(String button)

Parameter(s)

Name Description
button The name or index of button to be clicked. The name of the button is the name the programmer gave when of_addItem was called or when of_setText was last called. The name is the text displayed for a toolbar when display text is enabled. The index of the button is the same as the value returned when of_addItem was called

Return Value

Returns a long indicating the result of the call, ALLOW (1) if the call succeeded or PREVENT (-1) if there was an error.

Usage

Use this method when you want to execute the script associated with a button without user intervention.

In order to use this method, the item must be enabled and visible. If it is not, an error message is displayed and PREVENT is returned.

Examples

of_clickButton('Exit')

See Also

Last edited Sep 24, 2016 at 2:57 PM by cjharris02892, version 6