StrToDatatype
The DatatypeToStr function returns the data type number corresponding to the data type name. For example passing "float" returns 5.
number = StrToDatatype( string )
string is the data type name from the Mira Data Types table.
numberis the data type code from the Data Types table.
The example below converts data type "float" to to its number:
s = "float" |
-- data type "float" |
t = StrToDatatype( s ) |
-- get the corresponding number |
Printf("name=%s, stype=%d", s, t ) |
-- result: name="float"type=5 |