Sign In
Products
ZPL ViewerBarcode GeneratorImage → ZPLZPL cheat sheetLabel DesignerTemplate Gallery
Developers
API QuickstartAPI ReferenceMCP ServerBulk GenerationWebhooksSDKs & ExamplesLimitsDirectPrint agent NewGitHub ActionVS Code extensionOn-Premise
Solutions
Logistics & ShippingE-CommerceERP & WMSManufacturingRetailHealthcare & LaboratoryAll solutions
Tools
ZPL Diagnostics HubZPL DebuggerSize & DPI AnalyzerDPI ConverterBarcode fit calculatorShipping Label AnalyzerFont InspectorOrientation DebuggerCalibration AssistantPrinter Compatibility CheckerBarcode Readability CheckerPrinter Language DetectorThermal Printer Test PackZPL ToolsEPL ToolsTSPL ToolsCPCL ToolsPrinter Language ConverterAll ToolsGuidesPricing
Language
EnglishTürkçeDeutsch
Home›All EPL commands›B

B — Barcode field

Draws a barcode: type letter, narrow/wide bar ratio, height and the human-readable flag are read from the parameters.

Engine status: Partially rendered

The command is drawn but some of its parameters are ignored; the detail is in the note below.

Syntax

Bx,y,rot,type,narrow,wide,h,B/N,"data"

Example

N
q812
Q1218,24
B50,150,0,1,3,7,120,B,"123456"
P2

Open this example in the preview →

Open the validator →

Rendered example

B50,150,0,1,3,7,120,B,"123456"

Output of the example above in our renderer (203 dpi). Not verified on a physical printer.

Parameters

ParameterMeaning
x,yTop-left corner of the barcode, in dots
rotRotation code 0–3 in clockwise quarter turns, as in the A command
typeBarcode type code: 1 Code 128, 3 Code 39, E30 EAN-13, UA0 UPC-A in the preview
narrowNarrow bar width in dots; sets the module width of the drawn barcode
wideWide bar width in dots; accepted but not used by the Labelixa preview
hBar height in dots, without the human-readable line
B/NB prints the human-readable line under the bars, N leaves it out
"data"Barcode data in double quotes; empty data is skipped with a warning

Common mistake

Using the TSPL/CPCL type name: in EPL, Code 128 is type 1, not 128. B50,150,0,128,3,7,120,B,"123456" names an unsupported type and the preview skips the barcode.

The same job in other languages

ZPL equivalent: ^BY · ^BC · TSPL BARCODE · Language comparison

All EPL commands

N · q · Q · A · LO · LW · X · P · R · S · D · I · JF · ZT · ZB · FS · FE · FR · FK · FI · V · ?

All EPL commands