Print ZPLII QR to open url

﹥>﹥吖頭↗ 提交于 2020-01-22 02:55:07

问题


I'm using Zebra ZPLII to create a label with a QR code to open an specific url. When I use iPhone camera to scan the QR phone shows "unusable data" and when I try with an external QR reader the text extracted from the QR is not the same from the label. For example if I write www.google.com the string that I have from reading the QR is .google.com if I use https://www.google.com the result is ps://www.google.com

This is my label desing

^XA
^FX Top section with company logo, name and address.
^CF0,60

^FO220,50^FDIntershipping, Inc.^FS
^CF0,30
^FO220,115^FD1000 Shipping Lane^FS
^FO50,155^GB700,1,3^FS

^FX Third section with barcode.
^BY5,2,70
^FO300,95^BQN,2,4^FDwww.google.com^FS

^XZ

For testing I'm using http://labelary.com/viewer.html


回答1:


You are missing some of the parameters for the ^BQ and ^FD commands.

^BQ parameters:

^BQa,b,c,d,e

Where

a = Orientation
b = Model
c = Magnification factor
d = Error correction
e = Mask Value

The last two parameters are actually brought into the ^FD command after the ^BQ. Strange design, but that's how it works.

Full Barcode String

^FO300,95^BQN,2,6,M,7^FDQA,www.google.com^FS

Full ZPL for sample label

^XA
^FX Top section with company logo, name and address.
^CF0,60
^FO220,50^FDIntershipping, Inc.^FS
^CF0,30
^FO220,115^FD1000 Shipping Lane^FS
^FO50,155^GB700,1,3^FS
^FX Third section with barcode.
^BY5,2,70
^FO300,95^BQN,2,6,M,7^FDQA,www.google.com^FS
^XZ

Documentation:

https://support.zebra.com/cpws/docs/general/EncodingUnicode_QRCode.pdf https://support.zebra.com/cpws/docs/zpl/13979l-010_ra.pdf




回答2:


Find an easy solution, seems that the problem is that all the text after ^FD is not interpreted as text or something like that. To solve my problem I just did this:

^FO300,95^BQN,2,4^FDwww.google.com^FS

change to this:

^FO300,95^BQN,2,4^FD             www.google.com^FS


来源:https://stackoverflow.com/questions/59253262/print-zplii-qr-to-open-url

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!