CODE Function
All characters have a character code, and Excel will tell you what it is if you apply the CODE
function to them. The CODE
function returns a numeric code for the first character in a text string. The returned code corresponds to the character set used by your computer.
You can use the CODE
function in various ways depending on your specific needs. For example, the formula =CODE("H")
returns 72
, which is the numeric code of H
:
=CODE("a")
returns97
=CODE("A")
returns65
=CODE(1)
returns49
CHAR Function
The CHAR
function returns a character based on a numeric code. The numeric code can range from 1
to 255
, and corresponds to the character set used by your computer. For example, CHAR(65)
returns A
, CHAR(97)
returns a
, and CHAR(169)
returns ©
.
You can use the CHAR
function to insert special characters or symbols into your worksheets, such as bullets, or currency symbols.
=CHAR(165)
returns¥
=CHAR(163)
returns£
=CHAR(162)
returns¢
=CHAR(128)
returns€