typetest

typetest

Evaluates a variable to see if it is of the specified data type.  Typetest is a very useful way to make sure you have successfully loaded a variable before using the variable in a math or conditional expression. 

Attributes:

var: the variable to be tested
type: "int", "double"
result: the variable to store the result in
Examples:
<set vars="ANint,Adouble" values="3341,3341.1212" />

<typetest var="ANint" type="int" result="TorF" /> TorF=True
<typetest var="ANint" type="double" result="TorF" /> TorF=True
<typetest var="Adouble" type="double" result="TorF" /> TorF=True
<typetest var="Adouble" type="int" result="TorF" /> TorF=False