AsciiBase
Returns or sets the number base of the digits that an ASCII escape sequence captures.
Get
Returns an AsciiEscapeBase value.
Syntax: object.AsciiBase
- object
- required An object expression that evaluates to an EscapeSequence.
The default value is Octal. The value matters only when IsAsciiCharacter is True.
Let
Declared Friend. Sets the number base.
Syntax: object.AsciiBase = value
- value
- An AsciiEscapeBase value: Octal (0) or Hexadecimal (1).
Remarks
Create sets the property from its base argument. Execute reads the captured digits with the prefix &O for Octal and &H for Hexadecimal.
Example
Dim esc As EscapeSequence
Set esc = EscapeSequence.Create("\\x(\w{2})", vbNullString, True, Hexadecimal)
Debug.Print esc.AsciiBase ' 1
Set esc = EscapeSequence.Create("\\(\d{3})", vbNullString, True)
Debug.Print esc.AsciiBase ' 0
See Also
- IsAsciiCharacter property – whether the base is used
- Create method – sets the base
- AsciiEscapeBase enumeration – the number bases
- EscapeSequence class – overview