Function Comparisons Class

IsOn

Return True if the argument vValue is "On".

Signature (Visual Basic / VBA)

Public Function IsOn( _
    ByVal vValue As Variant _
    ) As Boolean

Code Example

    IsOn(23) = True
    IsOn(0) = False
    IsOn("Hello.") = False
    IsOn("True") = True
    IsOn("False") = False
    IsOn("1") = True

Parameters

Parameter Description
vValue Value which is checked to see if it is True. If vValue is numeric, return True if it is NON-zero. If vValue is a string, return True if it equals "on", "true", "yes", "1", or "+". Function returns False otherwise.

Notes & Version History

Note This is the opposite of the IsFalse function.
Note This is the same as the IsTrue function.