1
execstr Scilab Group Scilab Function execstr
3
execstr - execute Scilab code in strings
7
ierr=execstr(instr,'errcatch' [,msg])
9
instr : vector of character strings, Scilab instruction to be
12
ierr : integer, 0 or error number.
14
msg : character string with values 'm' or 'n'. Default value is
18
Executes the Scilab instructions given in argument instr.
20
If the 'errcatch' flag is not present, error handling works as usual.
22
If the 'errcatch' flag is set, and an error is encountered while
23
executing the instructions defined in instr, execstr issues no error
24
message, but aborts execution of the instr instructions (at the point
25
where the error occurred), and resumes with ierr equal to the error
26
number. In this case the display of the error message is controlled by
29
"m" : error message is displayed and recorded.
31
"n" : no error message is displayed, but the error message is
32
recorded (see lasterror). This is the default.
35
execstr('a=1') // sets a=1.
36
execstr('1+1') // does nothing (while evstr('1+1') returns 2)
38
execstr(['if %t then';
45
execstr('a=zzzzzzz','errcatch')
46
execstr('a=zzzzzzz','errcatch','m')
48
evstr, lasterror, error