RunScriptCommand2 Function

 

(Added in version 21, build on August 4, 2020)

This function is available starting with the pwrworld 21.0 type library.

 

The RunScriptCommand2 function is used to execute a list of script statements. The script actions are those included in the script sections of the Auxiliary Files. This function differs from RunScriptCommand in that it allows informational messages to be returned from the script execution when the execution is successful.

 

Function Prototype

RunScriptCommand2(Statements, out StatusMessage)

 

Parameter Definitions

Statements : String The block of script actions to be executed. Each script statement must end in a semicolon. The block of script actions should not be enclosed in curly braces.

StatusMessage : String This is an out parameter that returns any informational or error messages resulting during execution of the script command.

 

Output

Boolean result indicating if the script command was successful or not. If False is returned, an error message will be returned in StatusMessage. StatusMessage may be blank if True is returned.