Reports whether the value of a string is a number.
IsNumber ( string )
Argument |
Description |
---|---|
string |
A string whose value you want to test to determine whether it is a valid number |
Boolean. Returns true if string is a valid number and false if it is not.
This expression returns true:
IsNumber("32.65")
This expression returns false:
IsNumber("A16")
This expression for a computed field returns “Not a valid age” if age does not contain a number:
If(IsNumber(age), age, "Not a valid age")
To pass this validation rule, Age_nbr must be a number:
IsNumber(Age_nbr) = true
IsNumber in the PowerScript Reference