toUnicode

Summary

Returns the 16-bit Unicode value as a string.

Usage

public string toUnicode()

Returns

The 16-bit Unicode value of the character.

Description

Returns the 16-bit Unicode value of the character as a string.

All results are four (4) characters in length. If the 16-bit Unicode value would not otherwise be four characters in length, it is prefixed with zeros until a length of four is reached.

Examples

Basic Usage
1
2
`a`.toUnicode(); // "0061"
`b`.toUnicode(); // "0062"

Share

HTML | BBCode | Direct Link