Hi,
I wanted to print my pdf file (which actually a label in pdf format) into a "4x6" inch label print. When I go manually I can open the file through adobe reader and change the print settings to 4x6 size and print to my zebra 203 dpi printer. It print well to zebra printer.
But I wanted to handle this process through Progress Code. Any idea how can I do that?
Any help will be highly appreciated.
-
Thanks,
Ankit
Hi Ankit,
you can print directly to Zebra without generating the PDF. To do this, follow the following format:
/* direct to printer name found at windows\start\printers */
DEFINE STREAM s-saida.
OUTPUT STREAM s-saida TO printer value("ZDesigner S4M-203dpi ZPL (1)").
put stream s-saida CONTROL
"^XA^LH0,0^CI0^XZ" +
/* ^FO command sets a field origin x,y and ^FS command denotes the end of the field definition*/
"^FO45,42^FS" +
/* command sets the field position x,y */
"^FT81,118" +
/* command allows you to print text into a defined block type format. */
"^FB648,3,0,C,0" +
/* command specifies the font to use in a text field */
"^A0N,78,90" +
/* command defines the data string for a field. */
"^FD" + "TEXT TO PRINT" +
/* command denotes the end of the field definition */
"^FS" +
/* command is the ending (closing) bracket. It indicates the end of a label format. */
"^XZ".
OUTPUT STREAM s-saida CLOSE.
To format label length and width, use instruction ^LL to length and ^PW to width. To use ^LL you need to set ^JM (dots per millimeter) first then calculate label length and set ^LL and ^PW. See more at manual (zpl-zbi2-pm-en.pdf) search at google:
Hi Eduardo Silva,
Thanks!!...But this not what I need here. I got your point what you illustrate above is a fresh label printing.
I have received the complete label with text and bar code etc well in place in pdf file format from our client. So when I am opening that pdf label in adobe reader and change the print setting making print size 4x6 inch and put it to zebra printer it prints well. I wanted to handle this thing programmatically changing the print setting for that pdf file and put it to my zebra printer. So is there any approach available which will allow me to do so.
So I think for this I need to get the access to adobe reader internal structure through program.
Thanks,
Ankit
Any one have any idea about this topic.
Hi,
I think you can setup a copy of your Zebra printer with the correct paper size. This way your print program does not need to change the print settings during run time.
Gunnar
Hi Gunnar,
My zebra printer setup is correct for .ZPL file and its working correct for that. But my requirement here is to print the .PDF (A4 size) to Label size (4'X6') to my Zebra Printer. So I am in search for changing this printer settings at run time.
Thanks,
Ankit