Remapping the Zebra Code Page to Match the Windows Code Page

 Description

 This article describes how to troubleshoot the following situation:

Explanation:
All characters that display or print have a numeric value. Each value is actually a code point into a table of values, known as a code page, that describe all characters supported by that code page. The issue is that the Windows Code Page and the Zebra Code Page do not match. Most of the characters in the two code pages match, like numbers, lower and upper case letters, and punctuation symbols, but some, like the copyright, registered, and degree signs do not. [ © ® ° ]

The screen shots of the Windows Character Map below shows the copyright symbol has a value of 169 decimal (A9 hexadecimal) and the degree sign has a value of 176 decimal (B0 hexadecimal). However, the Zebra Code Page #850 shown below indicates that position 169 is the registered symbol (not the copyright) and position 176 is a "checkerboard" character and not the degree sign. Also note that the Copyright symbol has a value of 184 in the Zebra Code Page and the degree sign has a value of 248.

So, if you attempt to print a label from Loftware that contains a Copyright Sign (position 169) or degree sign to a Zebra printer, you'll get the Registered Sign or checkerboard symbol instead.

Windows Character Map


Zebra Code Page 850 ( partial extract )
 

Solution

 There are two common solutions to adjust the misalignment between Windows and Zebra code pages.

  1. Switch the Font Category property of the label fields from Native Fonts to True Type Fonts. When True Type fonts are used, Loftware will send an image of the character(s) to the printer so the Zebra code page is not involved in printing the character.
  2. Use the Zebra ^CI command to "remap" the expected MS Windows character to the matching character position in the Zebra Code page. The ^CI command can be used as a custom command at either the label or printer level within Loftware. The ^CI command has the format:

^CIa,s1,d1,s2,d2,...

Where:

    • a = The desired character set (default is 0 - USA 1)
    • s1 = The source 1 character (the character you want to print) from the Zebra code page
    • d1 = The destination 1 character value (from Windows)
    • s2 = The source 2 character (the character you want to print) from the Zebra code page
    • d2 = The destination 2 character value (from Windows)

In the example below. The ^CI command is being used to remap position 184 in the Zebra Code page to position 169 in the Windows code page so the Copyright sign will print as expected. Also being remapped is position 248 in the Zebra code page, the degree sign, to 176 which is the value for the degree sign in MS Windows.
The command ^CI0,184,169,248,176 is being sent "After ZPL Control Strings" in the printer options for a Zebra 170XiIII, and the values mean:

  • ^CI0 = Change character for USA1 character set
  • 184 = Value of the copyright sign in the Zebra code page
  • 169 = Value of the copyright sign in the Widows code page
  • 248 = Value of the degree sign in the Zebra code page
  • 176 = Value of the degree sign in the Widows code page



Further information about the ^CI ZPL command and the values and characters within the Zebra code page can be found in the Zebra ZPL2 Programming Guide available for download from the Zebra web site, www.zebra.com.

Values for characters within the Windows code page can be found using the Character Map tool within Windows
(Start|All Programs|Accessories|System Tools|Character Map).

A "Before" and "After" sample label is shown below using the copyright and degree characters mentioned in this document. When viewing the label in Design 32, the copyright and degree symbols appeared correct but printed incorrectly. The "After" label used the zpl custom command shown above (^CI0,184,169,248,176) to correctly print the desired characters.