今天用ZEBRA P4T開(kāi)發(fā)打印程序,開(kāi)發(fā)語(yǔ)言用C#。
開(kāi)始用CPCL打印語(yǔ)言測(cè)試,一直有個(gè)問(wèn)題解決不了。就是打印位置一直在2個(gè)黑標(biāo)中間。本身標(biāo)簽做的也不是很標(biāo)準(zhǔn)。找不到解決方法。
然后用ZPL測(cè)試,ZPL認(rèn)紙正常,但是打印的時(shí)候,出一張標(biāo)簽以后,會(huì)連續(xù)出18CM(每張標(biāo)簽1CM)左右才停止。
認(rèn)為是默認(rèn)標(biāo)簽大小的問(wèn)題引起的。查看ZPL幫助,只看到一個(gè) "~JC"命令可以測(cè)試紙張。測(cè)試以后還是沒(méi)有解決問(wèn)題。上GOOGLE搜索。
終于找到解決方法,上面的測(cè)試漏了一個(gè)保存步驟。
ZPL emulation
If one is using ZPL emulation, the printer needs to be calibrated before it will recognize label lengths within ZPL.
Below is an example of a file that one can send to the printer either through Label Vista or by copying the file through a DOS command prompt. (c:>copy filename.txt com1)
~JC This command tells the printer to calibrate
^XA ZPL starts with a ^XA
^JUS This command tells the printer to save the settings
^XZ ZPL ends with "^XZ"





