Programmer Guide/Command Reference/INTERPRET: Difference between revisions

From STX Wiki
Jump to navigationJump to search
m (1 revision: Initial import)
mNo edit summary
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{DISPLAYTITLE:{{SUBPAGENAME}}}}
{{DISPLAYTITLE:{{SUBPAGENAME}}}}
==INTERPRET==
{{Command Reference}}
 
INTERPRET <var>variable</var>
<code>INTERPRET [ <var>cmdVar</var>=ICMD <var>resVar</var>=IRES [ <var>historyTable</var> ]]</code>
The <code>INTERPRET</code> command interpretes the contents of the supplied variable as an {{STX}} command, and executes the respective command. <code>INTEPRET</code> returns the empty string on success, otherwise it will return an error message.
 
Interpret the contents of a variable as a command. The command returns <code>0;</code> on success, <code>1;errorMessage</code> if there was a parsing error, otherwise it returns <code>2;</code>.
 
;<var>cmdVar</var>
 
:The id of a variable. If neither <var>cmdVar</var> nor <var>resVar</var> are specified, the variable <code>ICMD</code> is used.
 
;<var>resVar</var>
 
:The id of a variable to store the executed command's result in. If neither <var>cmdVar</var> nor <var>resVar</var> are specified, the variable <code>IRES</code> is used.
 
;<var>historyTable</var>
 
:A simple table to which the command should be appended. If the command is already in the history, moved to the end.

Latest revision as of 08:54, 13 May 2015

INTERPRET variable

The INTERPRET command interpretes the contents of the supplied variable as an STx command, and executes the respective command. INTEPRET returns the empty string on success, otherwise it will return an error message.

Navigation menu

Personal tools