StrCharCount

Counts the number of characters in a string.

Syntax:

StrCharCount(string)

Parameters:

(s) string any text string.

Returns:

(i) the number of characters in a string,

 

Use this function to count the number of characters in a string. This function is useful when dealing with double-byte character sets such as those containing Kanji characters. When using single byte character sets, such as those found in English versions of Windows, this function is identical to the StrLen function.

Example:


name = AskLine("Data Entry", "Please enter your name", "", 0)
len = StrLen(name)
chars = StrCharCount(name)
Message(name, "Is %len% bytes long and %@CRLF% has %chars% characters")
See Also:

StrInsert, StrLen, StrByteCount, StrOverlay, StrScan, StrReplace, StrFill