Click or drag to resize

IsBDigit Function

X#
Determine if the leftmost character in a string is a binary digit (0 or 1).

Namespace:  XSharp.Core
Assembly:  XSharp.Core (in XSharp.Core.dll) Version: 2.21
Syntax
 FUNCTION IsBDigit(
	pszString AS STRING
) AS LOGIC
Request Example View Source

Parameters

pszString
Type: String
The string to examine.

Return Value

Type: Logic
TRUE if the first character of the string is 0 or 1; otherwise, FALSE.
Remarks
Examples
These examples demonstrate various results of IsBDigit():
X#
1? IsBDigit("AbcDe")        // FALSE
2? IsBDigit("1abcd")        // TRUE
3? IsBDigit("012345")    // TRUE
4? IsBDigit("21345")        // FALSE
See Also