Using ASCII and ANSI Characters

by Allen Wyatt
(last updated May 31, 2013)

5

Word allows you to add just about any character you can think of to your document. You add most characters by using the keyboard or by choosing Symbol from the Insert menu or, in Word 2007, choosing Symbol from the Symbols group on the Insert tab of the ribbon. Regardless of how you enter a character, Word tracks each one internally using a special numeric code. This code is necessary because computers can only understand numbers, not actual alphabetic characters. This numeric code is called either the ASCII or ANSI code.

In small computers, the code most often used is called ASCII, which is an acronym for American Standard Code for Information Interchange. It is a code comprised of 128 symbols assigned to the values 0 through 127. For instance, the letter A is represented in the computer by the number 65.

If you know the ASCII code for a particular character, and you want to enter it into your document, you can do so by holding down the Alt key and pressing the three-digit code on the numeric keypad. For instance, the ASCII code for an uppercase A is 65. You could enter this character by holding down the Alt key and pressing 065 on the numeric keypad. (Remember, you need to use a three-digit code.) Word responds by displaying the character on your screen.

A variation on the ASCII code is referred to as the ANSI code. (ANSI is an acronym for the American National Standards Institute.) The ANSI code can be considered a superset of ASCII, because it can represent many more characters than can be represented with the ASCII code. Remember that plain ASCII can represent only 128 characters. From a technical standpoint, this is because each character is represented using a single byte of data storage. ANSI, on the other hand, uses two bytes for storing each character, and can therefore be used to represent approximately 65,000 characters. The added flexibility provided by the ANSI code is necessary in today's international market for software.

ANSI characters are entered in your document in a similar fashion to ASCII codes. You hold down the Alt key, but instead use a four-digit code. For instance, if you wanted to insert the symbol for the British pound, you would hold down the Alt key and press 0163 (the four-digit code) on the numeric keypad. Word responds by placing the character in your document.

If you need to know more about either the ASCII or ANSI codes, any good programmer's reference will provide the information you need.

WordTips is your source for cost-effective Microsoft Word training. (Microsoft Word is the most popular word processing software in the world.) This tip (1359) applies to Microsoft Word 97, 2000, 2002, and 2003.

Author Bio

Allen Wyatt

With more than 50 non-fiction books and numerous magazine articles to his credit, Allen Wyatt is an internationally recognized author. He  is president of Sharon Parq Associates, a computer and publishing services company. ...

MORE FROM ALLEN

Automatic Row Height For Merged Cells with Text Wrap

When you have text wrap turned on in a cell, Excel expands the height of the row as you add more text to the cell. When you ...

Discover More

Hiding Smart Tags

If you don't want to see Smart Tags displayed in your document, you can instruct Word to hide them. Here's how to make the ...

Discover More

Working with Table Columns and Rows

Need to add or delete columns and rows from a table? It's easy to do using the tools provided in Word.

Discover More

Create Custom Apps with VBA! Discover how to extend the capabilities of Office 2013 (Word, Excel, PowerPoint, Outlook, and Access) with VBA programming, using it for writing macros, automating Office applications, and creating custom applications. Check out Mastering VBA for Office 2013 today!

MORE WORDTIPS (MENU)

Capitalizing the Word "I"

The first-person, singular pronoun "I" should always be capitalized, unless you are exercising poetic license. Word may not ...

Discover More

Symbols for Non-Printing Characters

Displaying non-printing characters can help you better understand the formatting and contents of your documents. What do all ...

Discover More

Inserting a Non-Breaking Hyphen

Non-breaking hyphens can come in helpful for some types of writing. They force the words (or characters) on both sides of the ...

Discover More
Subscribe

FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."

View most recent newsletter.

Comments for this tip:

If you would like to add an image to your comment (not an avatar, but an image to help in making the point of your comment), include the characters [{fig}] in your comment text. You’ll be prompted to upload your image when you submit the comment. Images larger than 600px wide or 1000px tall will be reduced. Up to three images may be included in a comment. All images are subject to review. Commenting privileges may be curtailed if inappropriate images are posted.

What is 9 - 7?

2016-03-24 01:59:40

winston

"ANSI" does not use two bytes for storing each character. It uses one byte (0..255). See https://en.wikipedia.org/wiki/Code_page#Windows_.28ANSI.29_code_pages for "ANSI" Codepages.

7Bit-ASCII uses 7 Bit (0..127). 8Bit-ASCII uses 1 Byte (0..255).
Unicode uses up to 4 Bytes.

It is possible to input Unicode characters via ALT-Code. See https://en.wikipedia.org/wiki/Alt_code


2015-09-30 13:48:47

Kari

I want to try pressing alt 065 on a MAC in Microsoft Word. The alt key is a bit different to use. It's not working. Any suggestions?


2013-04-11 10:55:05

siraj

interesting & very informative for those who want to know how to type ANSI & ASCII charecters,


2013-03-03 17:02:13

Brian McCabe

A very useful website.


2011-12-07 01:20:33

Rameshkumar

Excellent tips. Thank you.


This Site

Got a version of Word that uses the menu interface (Word 97, Word 2000, Word 2002, or Word 2003)? This site is for you! If you use a later version of Word, visit our WordTips site focusing on the ribbon interface.

Newest Tips
Subscribe

FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."

(Your e-mail address is not shared with anyone, ever.)

View the most recent newsletter.

Links and Sharing