getomlvar

Imports the OML variable value to the Tcl variable.

Syntax

set status [getomlvar omlvariablename tclvariablename]

Inputs

omlvariablename
Any valid OML variable name as a string.
Type: string
OML Variable Type Tcl Variable Type Limitations
Logical Bool
Number Int or Double
String String
Cell (1,n) n:number of elements in cell List Supports only if the cell contains following OML data types: Logical, Number, String
Struct Dictionary Structs with one dimension only supported. Supports only if the struct contains following OML data types: Logical, Number, String
Matrix Dictionary Supports only if the matrix contains following OML data types: Logical, Number
ND-Matrix Dictionary Supports only if the ND-matrix contains following OML data types: Logical, Number
tclvariablename
Any valid Tcl variable name as a string.
Type: string

Outputs

status
Status of importing the OML variable value to the Tcl variable.
1 = success
"error message" - failure
Type: int | string

Example

evalomlscript "x=9"
set status [getomlvar x tclx]
1