Air freight, Blogs, How-to, How-to, Sea freight, Transportation, Warehousing, Warehousing
DIY: 7 tips to modify an existing ZPL layout
Date
25 January, 2018
Reading time
5min. reading time
You probably do not even notice that almost every product contains a barcode. At least not me, until I became professionally aware of it while working at Boltrics. Recently, it struck me again when a cashier could not scan a barcode and had to manually retrieve the corresponding number sequence. As I had to wait in line, I realized again how obviously scanning a barcode has become and how it enables us to work more efficiently.
In the logistical process, products are often already provided with a barcode label, well before products reach the end customer. In many cases, it is a GS1-SSCC label. But labels with information about the batch or destination are also widely used. And it can also be an “anonymous carrier label”.
As a logistics service provider, you can use the data of such labels to facilitate your own process of goods in/out. By linking the data to your WMS system, you can register activities by simply scanning the barcode on products and pick locations. This will eliminate administrative tasks and reduce the number of mistakes. Side issue: you are able to follow products throughout the warehouse process.
In a series of four blogs, we will take a deep dive in the world of ZPL labels, how to change your own labels and share some tips & tricks. In my previous blogs, I explained how its structure is the basis of a good ZPL device, and I shared some background to the editor’s settings in 3PL and Nekovri Dynamics. In this blog, you can read more how you can change an existing ZPL layout. Comments with good additions are very welcome!
7 Tips to modify existing ZPL layouts
1. GS1 standard
Use the SSCC-Identifier functionality to retrieve the data according to the GS1 standard. To select values, choose “Identifier” in the function library. The Identifier number determines which value should be retrieved (see http://www.gs1-128.info/application-identifiers/).
2. Prevent label truncation
Driving your printer from two different systems and is your Dynamics label truncating? Add the code ^PW to the [Custom ZPL Formatting] field. Followed by a number depending on the printer’s DPI capabilities and the width of the label. The number is the number of DPIs / DPMMs that fit next to each other on the label.
Does your printer print “8 DPMM” (= 203 DPI inches), then place these 8 Dots on a millimeter. If you choose the number 1200, you will have a width of 125 mm at your disposal.
With ’12 DPMM ‘(= 300 DPI), the system places 12 to one millimeter. By 1200 you will have 10 cm of useful space.
3. Add database data
Use the F4 key in the field [Custom ZPL Format] to find keyboard shortcuts to insert database data on the label’s header. For example, your company details (name, address) or a logo.
4. Adding a logo
Import the image into the ZPL layout (first convert the image to text) and then add %7 to [Custom ZPL Format].
- You can convert the logo to text, for example, via the website the labelary.com. Remove the sample code and use “add image” to convert your image (max. 200 kb!).
- Copy the result code into Notepad and save this file as .txt file.
- Import this .txt file into the ZPL layout by clicking “Import image” in “Actions.”
- Do not forget to add %7 to [Custom ZPL Format].
5. Printing special characters
Use the code ^CI28 in [Custom ZPL Formattering] to print special characters correctly. For example: umlauts or ringel-s (ß).
6. Printing on a black background with white letters
Use a ZPL line to print a black rectangle as the background of the text in question. Enter the following as ZPL code: ~ BR with 7 parameters:
- x: The x-coordinate position of the rectangle’s top left corner, in pixels.
- y: The y-coordinate position of the rectangle’s top left corner, in pixels.
- width: The width of the rectangle, in pixels.
- height: The height of the rectangle, in pixels.
- r: The R (red) component of the rectangle color (0 to 255).
- g: The G (green) component of the rectangle color (0 to 255).
- b: The B (blue) component of the rectangle color (0 to 255).
For example: ~BR45,385,1100,80,0,0,0
Use a ZPL line to print the text on the specified background, using this ZPL code (the corresponding parameters are italic)
- ^CF font, font size
- ^FO x-coordinate-coordinate ¬- positioning the text
- ^FR – determines that the color should be calculated in relation to the background
- ^FD%1^FS -%1 determined that the value must be taken from the Function set or fixed text.
For example: ^CFB,10^FO50,390^FR^FD%1^FS
Both examples belong together. The black background is positioned slightly to the left of the text (x = 45 and x = 50) and slightly higher than the text to get a clean overlap.
7. Codes instead of a formatted label
Are there codes printed on the label instead of the desired text? Read the tips of Zebra Technologies how to make sure you can print a properly formatted label.