Function Character Types Class

IsPunct

"Is Character Punctuation" Return True if the character with ASCII value vCharCode is a punctuation character; return False otherwise. Punctuation characters include comma, period, quote mark, etc.

Signature (Visual Basic / VBA)

Public Function IsPunct( _
    ByVal vCharCode As Integer _
    ) As Boolean

Code Example

    IsPunct(Asc("%")) = True
    IsPunct(Asc("L")) = False
    IsPunct(Asc(" ")) = False

Parameters

Parameter Description
vCharCode Character whose ASCII value is checked to determine if it belongs to the punctuation class.

Notes & Version History

Note Function will generate a runtime error if vCharCode is not between 0 (zero) and 255 inclusive.