Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to printing Barcode of Laser Printer

Status
Not open for further replies.

eyaut

MIS
Aug 11, 2005
2
MY
Hello Everybody
My company want to print barcode to Laser Printer HP1300
and everybody can help me how to program for informix 4GL
thanks
 
You must embed the escape sequences with the 4GL statements. Here's an exaple where I print the barcode for 5 data elements using an HPL laserjet printer. THis is old code, so I don't remember the model number.

The point is you'll have to check your printer documentation:

Code:
LET prt_cmd_str =
    ASCII 27,"(0Y",               # Select barcode font
    ASCII 27,"(s0p8.1h12v0s0b0T", # Pitch set.
    ASCII 27, "&a9R",             # Line 9.2
    ASCII 27,"&a6C",              # Column 6
    "*",r_itmrcpt.receiptid CLIPPED,"*",
    ASCII 27, "&a12R",            # Line 12.2
    ASCII 27,"&a6C",              # Column 6
    "*",r_itmrcpt.pallet CLIPPED,"*",
    ASCII 27, "&a15R",            # Line 15.2
    ASCII 27,"&a6C",              # Column 6
    "*",r_itmrcpt.mm CLIPPED,"*",
    ASCII 27, "&a18R",            # Line 18.2
    ASCII 27,"&a6C",              # Column 6
    "*",r_itmrcpt.item CLIPPED,"*",
    ASCII 27, "&a21R",            # Line 21.2
    ASCII 27,"&a6C",              # Column 6
    "*",dispqty USING "&&&&&&","*",
    ASCII 27,"(0U",               # Ascii
    ASCII 27, "&a24R",            # Line 24
    ASCII 27,"(s0p10h6v0s0b3T"
 
  PRINT prt_cmd_str CLIPPED
 
Hello olded
I compile the program and follow your format to want print
the barcode and compile is ok
but can't print out barcode...

can you write a detail program let me reference
My printer is HP Laser printer 1300
thanks
 
I'm sorry, but I don't have access to an HP 1300. The documentation should describe the escape codes required.

Also, not every laser supports barcodes. Are you sure that yours does?

Sorry I can't be more help.

 
Another way to print barcodes is explained there:

Some resources are related to printing barcodes. The principle if far different than what is explained by 'olded'. It's in fact printing small black boxes.

We use Hp printers and this works.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top