Returns the script result from a performed sub-script.


Get ( ScriptResult )



Data type returned 

text, number, date, time, timestamp, container

Originated in version 



Use this function as part of a calculation evaluated within a script. If a sub-script doesn't return a result, then the contents of the script result will either be empty or the value of any previous sub-script result. To control the value of a sub-script result, use the Exit Script script step in the sub-script and specify a result.

Example 1 

In the following example, the Find Customers script returns the results of a find request when it is called from the Do Reports script. Script Find Customers uses the optional script result of the Exit Script script step. Script Do Reports then uses Get(ScriptResult) to determine what other script steps should be performed based on the returned result stored in Get(ScriptResult).

Find Customers

Set Error Capture [On]
Perform Find [Restore]
New Record/Request
Exit Script [Text Result: Get(FoundCount) < 10]

Do Reports

Perform Script [ Specified: From list ; "Find Customers" ;
Parameter: ]
If [Get(ScriptResult) = 0]
        Show Custom Dialog ["You have created 10 records already."]
End If