Identifies the type of an expression, a variable (during a call to a procedure for example) or a control.
PROCÉDURE MyProcedure(Parameter)
TypeVar(Parameter)
Syntax
<Result> = TypeVar(<Expression>)
<Result>: Integer
Identifies the type of variable or control value. 0 for the controls that return no value (button, OLE control, ...).
<Expression>: Character string
Name of WLanguage variable or control whose type is requested.
Remarks
String type and Unicode string
In Mobile, a Unicode string is considered as being a string:
MyString is UNICODE string
TypeVar(MyString) // returns wlString
In WINDEV or WEBDEV, a Unicode string is considered as being a Unicode string:
MyString is UNICODE string
TypeVar(MyString) // returns wlUnicodeString
System integer
- The system integer automatically adapts to the size supported by the compilation mode (4 bytes for a program compiled in 32-bit mode, 8 bytes for a program compiled in 64-bit mode).
- For applications compiled in 32-bit mode, TypeVar returns 8 (wlInt).
- For applications compiled in 64-bit mode, TypeVar returns 9 (wlInt_8).