Standard or higher

Barcode command line interface (CLI)

Generate barcodes at the command line

ActiveBarcode: Generate barcodes at the command lineYou can use the ActiveBarcode command line tool to create barcode images files directly from the command line. E.g. use it in batch or script programs.

The command line tool is included with ActiveBarcode and will be installed automatically when you install ActiveBarcode, unless you have unchecked this option. You'll find ActiveBarcodeCLI.exe in the folder you installed ActiveBarcode to. Usually: C:\Program Files\ActiveBarcode.

ActiveBarcode: Highly accurate barcodes
Highly accurate barcodes
ActiveBarcode: At the command line
At the command line
ActiveBarcode: Bitmaps and vector graphics
Bitmaps and vector graphics
ActiveBarcode: Automation
Automation
ActiveBarcode: Versatile in use
Versatile in use

Examples

ActiveBarcode: Barcode exampleThe following call of the tool will create a 400x200 pixels sized PNG image file named ean.png with an EAN-13 barcode encoding 192837465012.
ActiveBarcodeCLI ean.png -text=192837465012 -typename=ean13 -width=400 -height=200
One more example: The following call of the tool will create a 500x100 pixels sized PNG image file named code128.bmp with an Code 128 barcode encoding Hello World.
ActiveBarcodeCLI code128.bmp "-text=Hello World" -type=14 -width=500 -height=100

Command line parameters for the console

Usage:
ActiveBarcodeCLI filename [Parameter]
The following parameters can be used:

-text=


Example: -text=123456789012
Characters to be encoded.
You can enter control codes in human readable form like this: <CR>, <LF>, ...
ActiveBarcodeCLI gs1.png "-text=(02)00614141000418(15)210228(10)451214<FNC1>(37)20" -type=28

If you want to use the quotation mark within the text, you need to send it as ASCII code because it is also used as delimiter for parameters. You can enter any ASCII character as decimal ASCII code within angle brackets in the form <nnn>.

The quotation mark is ASCII 34, so just pass <034> instead.
Example to encode ABC"123:
ActiveBarcodeCLI test.png "-text=ABC<034>123" -type=14

-type=


Example: -type=0
Barcode type, referenced by an indexed number

-typename=


Example: -typename=CODECODE128
Barcode type, referenced by the name

-width=


Example: -width=500
Width in pixels

-height=


Example: -height=500
Height in pixels

-alignment=


Example: -alignment=1
Alignment
0=left
1=center
2=right

-borderwidth=


Example: -borderwidth=10
Borderwidth in pixels

-borderheight=


Example: -borderheight=1
Borderheight in pixels

-notchheightinpercent=


Example: -notchheightinpercent=25
The notch height in %

-showtext=off


Example: -showtext=off
No textline under the code

-forecolor=


Example: -foreground=000000 or -foreground=black
Sets the foreground color, hexadecimal RGB as RRGGBB
or with CSS/HTML color names

-backcolor=


Example: -background=FFFFFF or -background=white
Sets the background color, hexadecimal RGB as RRGGBB
or with CSS/HTML color names

-fontname=


Example: -fontname=arial
Font for the text line

-fontsize=


Example: -fontsize=8
Font size

-fontbold=


Example: -fontbold=on
Font bold (on/off)

-fontitalic=


Example: -fontitalic=on
Font italic (on/off)

-fontunderline=


Example: -fontunderline=on
Font underline (on/off)

-fontstrikeout=


Example: -fontstrikeout=on
Font strikeout (on/off)

-filetype=


Example: -filetype=bmp
The format of the image file determines i.a. whether the barcode is generated as raster graphics or freely scalable vector graphics.
(valid values: bmp, jpg, png, tif, tga, gif, wbm, pbm, pgm, ppm, xpm, wmf, emf)
Default: auto detect by extension of filename

-colordepth=


Example: -colordepth=24
Colordepth of the image file
(valid values: 1, 8, 16, 24, 36)

-flags=


Example: -flags=0x80

-angle=


Example: -angle=180
Rotates the image file
(valid values: 0-359)

-dpi=


Example: -dpi=300
Resolution in DPI for jpg, png, tif & bmp files

-echo=


Example: -echo=off
-echo=errors
-echo=verbose
off: Display no messages
errors: Display only errors
verbose: Display all messages and open barcode in ImageView