JavaScript Editor Ajax toolkit     Ajax website 



Main Page

Code includes an incorrect Unicode escape sequence, or a non-hexadecimal character is the first character in a hexadecimal literal.

Unicode escape sequences begin with \u, followed by exactly four hexadecimal digits. Hexadecimal literals begin with 0x, followed by any number of hexadecimal digits. Hexadecimal digits can contain only the numbers 0-9, the uppercase letters A-F, and the lowercase letters a-f. The following example demonstrates a correctly formed Unicode escape sequence.

В CopyCode imageCopy Code
z = "\u1A5F";

The following example demonstrates a correctly formed hexadecimal literal.

В CopyCode imageCopy Code
k = 0x3E8;

To correct this error

  1. Be sure that hexadecimal numbers contain only the numbers 0-9, the uppercase letters A-F, and the lowercase letters a-f.

  2. Be sure that the Unicode escape sequence contains four digits.

    NoteNote

    If you want to use the literal text \u in a string, then use two backslashes - (\\u) — one to escape the first backslash.

See Also



JavaScript Editor Ajax toolkit     Ajax website


©