Im using via command line follow
convert -font code-128 -pointsize 58 -fill black -size 400x100 xc:white -draw "text 20,80 'Ò,BÍ5VÓ'" barcmax.jpg
Print incorrect image of barcode
I am using Use code128 from http://sourceforge.net/projects/openbarcodes/
work right if print "Ò,BÍ5VÓ" via wordpad with "code 128" font selected
"Ò,BÍ5VÓ" is 12345 encoded
Thanks in advace
How generate a barcode code128 via command line?
Re: How generate a barcode code128 via command line?
Try this:
I have created the "canvas" first and put the correct filename of the barcode font.
Code: Select all
convert -size 400x100 xc:white -font code128.ttf -pointsize 58 -fill black -draw "text 20,80 'Ò,BÍ5VÓ'" barcmax.jpg
-
- Posts: 2
- Joined: 2018-01-23T08:47:03-07:00
- Authentication code: 1152
Re: How generate a barcode code128 via command line?
In code 128 there is the code '(apostrophe). I'm using the command:
convert -density 600 -size 2000x333 xc:white -font c:\windows\fonts\code128c.ttf -fill black -draw "text 20,333 'úC1,'D$dü!DYüHüNe;3UF'cjû' " C:\Carlos\dacte\test.jpg
The bar code is cutting because of the '
Any suggestion?
convert -density 600 -size 2000x333 xc:white -font c:\windows\fonts\code128c.ttf -fill black -draw "text 20,333 'úC1,'D$dü!DYüHüNe;3UF'cjû' " C:\Carlos\dacte\test.jpg
The bar code is cutting because of the '
Any suggestion?
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: How generate a barcode code128 via command line?
Have you tried using escaping the single quotes as \'.
This works fine for me on IM 6.9.9.23 Q16 Mac OSX
This works fine for me on IM 6.9.9.23 Q16 Mac OSX
Code: Select all
convert -size 200x200 xc:white -fill black -font arial -pointsize 18 -draw "text 20,20 'abc\'def\'ghi'" tmp.png
-
- Posts: 2
- Joined: 2018-01-23T08:47:03-07:00
- Authentication code: 1152
Re: How generate a barcode code128 via command line?
Thank you very much. Now it's 99%.
I still encounter problems running the command:
convert -density 600 -size 1500x333 xc:white -font c:\windows\fonts\code128c.ttf -fill black -draw "text 20,333 'úJ2!\'D$dü#&YüRü+7b-;"P/`û'" c:\carlos\test.jpg
When I run from the command line (DOS) it works perfectly.
But when I run with a BAT file, error occurs.
I still encounter problems running the command:
convert -density 600 -size 1500x333 xc:white -font c:\windows\fonts\code128c.ttf -fill black -draw "text 20,333 'úJ2!\'D$dü#&YüRü+7b-;"P/`û'" c:\carlos\test.jpg
When I run from the command line (DOS) it works perfectly.
But when I run with a BAT file, error occurs.
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: How generate a barcode code128 via command line?
Sorry I do not know Windows scripting. Try using Windows escapes ^' rather than \'