Skip to content
Math & Text charCodeAt

$charCodeAt — Returns the UTF-16 code of the character at an index (NaN when out of range).

Returns the UTF-16 code of the character at an index (NaN when out of range).

Syntax

$charCodeAt[text;index]

Parameters

  • text (text, required) — The text.
  • index (number, required) — Zero-based position.

Return Value

  • string.

Usage

$charCodeAt[A;0] → "65"

Example

$sendMessage[$charCodeAt[A;0]]

Try it

Paste an example into the playground to preview its message (functions that act on Discord are not run), or build the same thing with blocks.