今天用ZEBRA P4T开发打印程序,开发语言用C#。
开始用CPCL打印语言测试,一直有个问题解决不了。就是打印位置一直在2个黑标中间。本身标签做的也不是很标准。找不到解决方法。
然后用ZPL测试,ZPL认纸正常,但是打印的时候,出一张标签以后,会连续出18CM(每张标签1CM)左右才停止。
认为是默认标签大小的问题引起的。查看ZPL帮助,只看到一个 "~JC"命令可以测试纸张。测试以后还是没有解决问题。上GOOGLE搜索。
终于找到解决方法,上面的测试漏了一个保存步骤。
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"