A code page is a table that assigns a numeric value to each element in a collection of letters, numbers, punctuation, control codes, and other characters. The assignment is one-to-one: no two characters are assigned the same numeric value, and no two numeric values are assigned the same character.
The following figure shows the characters and numeric values of the IBM850 code page, widely used in western Europe and the Americas. The white area contains the characters, while the shaded areas contain the numeric values. By convention, numeric values are in hexadecimal. To compute the numeric value of a character, add the numeric value at the top of the character's column to the numeric value at the far left of the character's row. For example, the numeric value of the character "Ö" is 99 hex (90 hex + 9 hex), which equals 153 in decimal.
Figure 1. The IBM850 code page
The following figure shows the characters and numeric values of the ISO8859-1 code page, also widely used in western Europe and the Americas.
Figure 2. The ISO8859-1 code page
Here are some other important points about code pages:
The term code point refers to an element of a code page—that is, to a character and its numeric value. For example, in the ISO8859-1 code page, code point 4B contains the character "K" and the value 4B hex.
A code page can be multi-byte (1-4 bytes), depending on the maximum size of the numeric value in each entry. An example of a double-byte code page is BIG-5, used for Traditional Chinese. An example of a multi-byte code page is UTF-8, an encoding of Unicode. For more information on using multi-byte code pages in applications, see UsingMulti-byte Code Pages and Using Unicode.