Excel CHAR Function
Excel CHAR function returns a character value specified by a number. Excel CHAR function is categorized under Text function and is used to translate code page numbers into characters you receive from other files.
The syntax for Excel CHAR function is:
It has only one required argument;
Number: It is the number between 1 and 255 specifying characters you want from the character set used by your computer.
Excel CHAR function is the built-in function to specify a character in the formula that is difficult to use directly. As Excel CHAR function returns character based on character set, but this character set might be different for different operating systems. Therefore Excel CHAR function may return different character on different operating systems.
Windows operating system uses ANSI or ASCII/Unicode character set depending upon the version of Windows, and Macintosh (Mac) operating system uses Macintosh character set, so Excel CHAR function may return different character for a specified number when used on these both operating systems.
For example, if you specify a number in Excel CHAR function as CHAR(10) on the Windows operating system then formula adds a line break in a worksheet. But on Mac operating system Excel CHAR function uses a different number like CHAR(13) to add a line break in the worksheet.
For example, you have a list of specified numbers for which you want to return characters using Excel CHAR function on Windows operating system. The below table shows the results of Excel CHAR function for the following set of numbers:
Following points must be remembered while using Excel CHAR function:
- Excel CHAR function is available in Excel 2000 and all later versions.
- Excel CHAR function returns the result as text value or string
- It returns VALUE! error if the specified number is not an integer between 1 and 255
- Excel CHAR function is inverse of Excel CODE function
- For a number greater than 255, use Excel UNICHAR function.