Draws a 1D barcode: type, height, human-readable flag, rotation, narrow and wide bar width come from parameters.
Engine status: Partially rendered
The command is drawn but some of its parameters are ignored; the detail is in the note below.
BARCODE x, y, "type", h, readable, rot, n, w, "data"SIZE 100 mm, 150 mm
GAP 3 mm, 0 mm
CLS
BARCODE 100, 200, "128", 100, 1, 0, 3, 3, "123456"
PRINT 1Open this example in the preview →
Output of the example above in our renderer (203 dpi). Not verified on a physical printer.
| Parameter | Meaning |
|---|---|
x, y | Top-left corner of the barcode, in dots |
"type" | Symbology in double quotes; the preview draws 128, 39, EAN13 and UPCA |
h | Bar height in dots |
readable | 0 hides the human-readable line; the preview prints it for any other value |
rot | Rotation in degrees clockwise: 0, 90, 180 or 270 |
n | Narrow bar width in dots; sets the module width |
w | Wide bar width in dots; accepted but not used by the Labelixa preview |
"data" | Barcode data in double quotes; empty data is skipped with a warning |
Using EPL type codes: TSPL names the symbology, so Code 128 is "128", not "1". With "1" the preview skips the barcode with an unsupported-type warning.
ZPL equivalent: ^BY · ^BC · EPL B · Language comparison
SIZE · GAP · REFERENCE · CLS · TEXT · QRCODE · BOX · BAR · BITMAP · PRINT · DIRECTION · DENSITY · SPEED · OFFSET · SET · CODEPAGE · BLINE