Functions that Return type Num


ABS ( nVal )

Returns the Absolute value of nVal . Evaluates the expression Abs(nVal)

ABS ( 3.14 ) returns 3.14

ABS ( -3.14 ) returns 3.14


SIN ( nVal )

Returns the Sine value of nVal [degrees]. Evaluates the expression Sin(nVal)

SIN ( 30 ) returns 0.5


COS ( nVal )

Returns The Cosine value of nVal [degrees] . Evaluates the expression Cos(nVal)

COS ( 60 ) returns 0.5


MIN ( nVal1 , nVal2 )

Returns the the smaller of nVal1 and nVal2 .

MIN ( 3 , 5.4 ) returns 3


MAX ( nVal1 , nVal2 )

Returns The the greater of nVal1 and nVal2 .

MAX ( 3 , 5.4 ) returns 5.4


ROUNDUP ( nVal )

Returns the Num by rounding nVal up to the integer that is greater or equal to nVal.

ROUNDUP ( 3.78 ) returns 4

ROUNDUP ( -3.78 ) returns -3


ROUNDDOWN ( nVal )

Returns the Num by rounding nVal down to the integer that is less or equal to nVal.

ROUNDDOWN ( 3.78 ) returns 3

ROUNDDOWN ( -3.78 ) returns -4


SQR ( nVal )

Returns the square value for nVal. Evaluates the expression (nVal)2 

SQR ( 3 ) returns 9


SQRT ( nVal )

Returns the square root value for nVal. Evaluates the expression SQRT(nVal) 

SQRT ( 9 ) returns 3


TRUNC ( nVal )

Returns an integer by trimming nVal.

TRUNC ( 3.14 ) returns 3


LIMIT ( nVal , nMin , nMax )

Returns a Num where nVal is limited by nMin and nMax .

LIMIT ( 3.14 , 5 , 6 ) returns 5

LIMIT ( 5.2 , 5 , 6 ) returns 5.2

LIMIT ( 8 , 5 , 6 ) returns 6


BOOL_TO_NUM ( bVal )

Returns 1 if bVal is TRUE, otherwise returns 0


TEXT_TO_NUM ( sVal , nErrVal )

Converts Text sVal into a Num and returns it. If conversion fails returns nErrVal.

TEXT_TO_NUM ( 0.16 , 3 ) returns 0.16

TEXT_TO_NUM ( HelloWorld , 3 ) returns 3


GET_TEXTLEN ( sVal )

Returns a Num that represents the count of characters in sVal. Note that space is also included in character count. If sVal has no characters, returns 0.

GET_TEXTLEN ( Hello ) returns 5

GET_TEXTLEN ( Hello1 ) returns 6


GET_INDEXOF ( InputText , SearchText )

Searches for the first occurrence of SearchText within InputText, and returns the zero-based index of found position. If SearchText is not found, it returns -1

GET_INDEXOF ( HelloWorld , World ) returns 5

GET_INDEXOF ( HelloWorld , o ) returns 4

GET_INDEXOF ( HelloWorld , Test ) returns -1