MS Excel: IsNumeric Function (VBA only)
In Excel, the IsNumeric function returns TRUE if the expression is a valid number. Otherwise, it returns FALSE.
The syntax for the IsNumeric function is:
IsNumeric( expression )
expression is a variant.
Applies To:
- Excel 2007, Excel 2003, Excel XP, Excel 2000
For example:
IsNumeric(786) would return TRUE IsNumeric("Tech on the Net") would return FALSE IsNumeric("234") would return TRUE
VBA Code
The IsNumeric function can only be used in VBA code. For example:
Dim LValue As Boolean
LValue = IsNumeric("Tech on the Net")
In this example, the variable called LValue would contain FALSE as a value.