ZPL set label size reserve print - zebra-printers

I have some information I want to print out with a label size of 600 however I can't seem to get it to print the opposite way.
zpl code
! U setvar "ezpl.media_type" "mark"
setvar "zpl.label_length" "600"
END
^XA^LH110,10^FWR
^FO400,0^ASR,18,10^FDInformation^FS
^FO350,0^ASR,18,10^FD Instructions:^FS
^FO350,200^ASR,18,10^FD [instructions] ^FS
^FO250,0^ASR,18,10^FD address:^FS
^FO200,0^ASR,18,10^FD [address]^FS
^FO150,0^ASR,18,10^FD [street]^FS
^FO100,0^ASR,18,10^FD [city]^FS
^XZ
the issue I am having is it prints like.
"space" instructions : do this inste
and cuts it off after a few words. I can't seem to do negative x axis values to just force it to start at the beginning.
So is there a way to make it print in reserve?
so its
"way less space now" .xob siht htiw daetsni siht od : snoitcurtsni

Use ^LL to sent the Label Length. You are not setting that in the ZPL that you show as your example. You can see the Zebra ZPL Programming guide to see details on how to use the command. If you want 600 pixels long, then this should be your first line of ZPL:
^XA^LH110,10^LL600^FWR

Related

ZPL code sent to printer prints 2 blank labels before printing the actual label

The following ZPL code when sent to a Zebra GX-420D printer with 2"x2" labeld loaded, does 2 very strange things:
Skips the first 2 labels and only prints on the 3rd one
Repeat this (2 blank labels + one with content) one more time, after a short delay.
So in total it uses 6 labels, and the content is only on the 3rd and 6th one.
Here's the code:
^XA
^FX Test for long barcode
^BY1,2,50
^FO20,10^BC^FD>6UIQ-2013P-MR-BU^FS
^XZ
Is there anything in the above code that would cause this phenomenon?
^FS at the end of a commented text is optional.
From ZPL II manual :
The ^FS command denotes the end of the field definition.
Alternatively, ^FS command can also be issued as a single ASCII control code SI (Control-O, hexadecimal 0F).
I eventually figured it out. I was trying to remotely fix this, not having a direct access to the printer and not seeing what it printed and how. But eventually I got access to a printer and then it didn't take long to fix.
It seems that there were some defaults or setting left over from the previous print jobs that cause the problem. I added some resetting of values in front of the printing and after that it properly printed out just one label.
And yes, the ^FS was not needed at the end of the comment with ^FX.
Here is the code that printed out the same thing correctly (there might be some unnecessary commands but this one worked so I left it at that):
^XA~TA000~JSN^MNW^PON^PMN^LH0,000~SD15^XZ
^XA^JUS^XZ
^XA
^MMT
^PW0355
^LL0305
^FX Test for long barcode
^BY1,2,50
^FO20,10^BC^FD>6UIQ-2013P-MR-BU^FS
^XZ

How to print price without specyfing location of every part of the text? (ZPL)

The effect he wants to get is:
The price is normally printed
Near the price I want to print the rest of the price in superscript
At the end I want to place currency in subscript.
The problem is that I don't want to specify the location of every part of text.
^XA
^PW480
^FS
^JMA
^MMT
^LS0
^MTD
^CI28
^FO40,11
^FWN
^CF0,16.2,20.7
^FD2144
^FS
^CI28
^FO80,10
^FWN
^CF0,8,8
^FD00
^FS
^CI28
^FO100,10
^FWN^CF0,16.2,17.25
^FDEUR
^FS
^XZ
So the question is that possible to print text after text specifying location only once? Without specifying location to every part of the text?
Use ^FT instead of ^FO, and only specify the X coordinate for the first ^FT.
By default, ^FT resumes at the point where the previous formatting operation finished, and you can provide a manual override to the X and Y components separately, so you would only provide the Y override for the subsequent ^FTs and let it calculate the X automatically:
^FT40,11^A0,16.2,20.7^FD2144^FS
^FT,6^A0,8,8^FD00^FS
^FT,11^A0,16.2,17.25^FDEUR^FS
Note that you will need to adjust the Y coordinate down, because ^FO lines up with the top of the text line (letters hanging from it) and ^FT lines up with the bottom (letters standing on it).
Also note that ^CF changes the printer-wide default font, and there is no point to use it before each command. Use ^A instead as shown. You don't need to set ^CI before each command either, it is again a global setting for encoding of the entire label text.

Zebra RW 420 not printing last or first inch using ZPL

Zebra RW 420 not printing last or first inch(depending on rotation) using ZPL.
this link was suppose to give a solution since it is the same symptom; but I've try all combinations of "Back Feed" (~JSN, ~JSA, ~JSB) with no results.
here is my ZPL code(generated from ZebraDesigner print to file command) It doesn't print "Hello 22" completely:
^XA~TA000~JSN^LT0^MNM^MTT^POI^PMN^LH0,0^JMA^PR2,2~SD10^JUS^LRN^CI0^XZ
^XA
^MMT
^PW812
^LL2233
^LS0
^FO272,76^A0N,56,55^FH\^FDHello 11^FS
^FO320,2000^A0N,56,55^FH\^FDHello 22^FS
^PQ1,0,1,Y^XZ
I had the same problems with print output. I ended up abandoning use of ^FO and went with ^FT, and everything has been perfect since. I don't know why ^FO is so temperamental, but ^FT is very straightforward. You get what you expect.
I'd suggest getting rid of that entire first row that ZebraDesigner made. You don't need it.
I've solved the problem with the help of Zebra support.
The actual problem was the var "zpl.label_length" that was set to 2014 instead of 2233; the ^LL command is ignored in this printer and the label length is controlled only by "zpl.label_length".
It printed the whole label(11")after sending the command:
! U1 setvar "zpl.label_length" "2233"

ZPL to print strike through

Is there a way to use ZPL to print text with a strikethrough (a line through the text)?
I need to be able to print something and indicate that it was there. I have looked through the ZPL programming guide and I have not found any way to alter the font....
An alternative approach would be to draw a line through your text. Here is a sample. You would need to calculate the points of the line based on the coordinates of the text:
^XA
^FT62,93^A0N,42,40^FH\^FDstrikethrough^FS
^FO41,76^GB268,0,5^FS
^PQ1
^XZ
AFAIAA, No.
Could you simply draw a line over the required text? Perhaps you could use or manufacture a downloaded bitmap font which is "struck through?"
OTOH...
To underline - use a monospaced font like AA,AC,AD,AF or AG
Use
^FO350,50^AGR^FDwhatever,milk,butter,salt^FS
^FO340,50^AGR^FD ____ ______^FS
where the underline here is under milk and butter, you can adjust the offset by trimming the FO's X and Y positions by a few dots (10 X here). Naturally, that can be raised for strikethrough, too...

ZPL print barcode with extra text above

I am developing an application that prints labels using Zebra GK420t printer.
I successfully could print Barcode with the text value in the bottom of the Barcode.
However, I was not be able to print extra text above the Barcode.
I am using this command
^XA
^FO20,20^BY2
^BCN,100,Y,N,N
^FDvar^FS
^XZ
[Translated to ZPL from program code]
Which, if var is 'abc123', prints the Barcode with abc123 underneath.
Q: How can for example can I print my name above the Barcode???
If you mean "abc123 above the barcode" then change ^BCN,100,Y,N,N to ^BCN,100,Y,Y,N.
If you mean "Print 'Nabeel' above the barcode" then insert
^CFD^FDNabeel^FS
^FO20,50
After the ^FO20,20 line.
This would select internal font "D" (CFD) and print "Nabeel" at offset 20,20 (the preceding (^FO)) then set the position of the barcode to 20,50 since 20,20 is really close to top-left of the label.
I'll presume you know how to modify your program code.

Resources