Excel Office

Excel How Tos, Tutorials, Tips & Tricks, Shortcuts

CODE function: Description, Usage, Syntax, Examples and Explanation

What is CODE function in Excel?

CODE function is one of TEXT functions in Microsoft Excel that returns a numeric code for the first character in a text string. The returned code corresponds to the character set used by your computer.

Operating environment Character set
Macintosh Macintosh character set
Windows ANSI
Also See:   How to abbreviate names or words in Excel

Syntax of CODE function

CODE(text)

The CODE function syntax has the following arguments:

  • Text    Required. The text for which you want the code of the first character.

Example of CODE function

Steps to follow:

1. Open a new Excel worksheet.

2. Copy data in the following table below and paste it in cell A1

Also See:   Remove unwanted characters in Excel

Note: For formulas to show results, select them, press F2 key on your keyboard and then press Enter.

You can adjust the column widths to see all the data, if need be.

Formula Description Result
=CODE(“A”) Displays the numeric code for A 65
=CODE(“!”) Displays the numeric code for ! 33
Also See:   How to abbreviate names or words in Excel

Leave a Reply

Your email address will not be published. Required fields are marked *