Name
Chr -- convert code point value to string
Synopsis
var$ = Chr(value[, encoding])
Function
Converts the code point value specified in value into a string.

The optional encoding parameter can be used to set the character encoding to use. This defaults to the default string encoding set using SetDefaultEncoding(). See Character encodings for details.

If you want to work with raw bytes instead of code points, you can either set the encoding parameter to #ENCODING_RAW or use the ByteChr() function. See ByteChr for details.

Inputs
value
code point value
encoding
optional: character encoding to use (defaults to default string encoding) (V7.0)
Results
var$
resulting string
Example
test$ = Chr(65)
Print(test$)
This will print "A" to the screen because 65 is the code point value for "A", in both ASCII and Unicode character encodings.

Show TOC