IsInteger()
Checks whether the specified value is an integer. This function takes an argument of any type and returns a Boolean value. If the value is an integer, the function returns the Boolean value TRUE
. If the value is not an integer, the function returns the Boolean value FALSE
.
Syntax
IsInteger(<value>)
Input
value
Boolean, date, integer, number, string
The value to check.
Output
Boolean
Examples
Assume that you have a form in which there is a text question and a number question. The text question has the reference name first_name and was answered Lee. The number question has the reference name number_of_cars and was answered 2
.
- The expression
IsInteger($number_of_cars)
returnsTRUE
. - The expression
IsInteger(2)
returnsTRUE
. - The expression
IsInteger(2.0)
returnsFALSE
. - The expression
IsInteger($first_name)
returnsFALSE
. - The expression
IsInteger("Lee")
returnsFALSE
.