Barcode

sevil

New Member
Hi everbody,
Recently, we want to print barcodes from Mfg/Pro. We use HP printer. How can we do this? Or is there anyone that has such experience? For example must we use PCL? Please help us. Thanks.
 
U

Unregistered

Guest
we had to deal with such task in the past.

1) if you have a Kyocera printer (which is widely used by the distribution people), they have a proc language very easy to use and very practical for printing barcodes

2) if you have an other printer (PCL 5 compatible ou postscript), you may buy a small piece of software with will do the job of transcripting your barcode request to the correct PCL5 instructions. We know of one in France whixh name is "HyperLabel".

That's all so far. HOpe it will help you.
 

rbaggetta

New Member
I'm currently in the process of implementing both Intermec barcode printers and Lexmark Laser printers. Both areas require different setups under a unix enviornment. Have tried talking to your HP rep, or a Lexmark rep? There are numerous ways of printing barcodes through MFG/PRO. Question is, how integrated do you want it to be? What are they willing to spend to get going? Also, you can try looking at software to read MFG/PRO flat files via an ftp session. I know Loftware and Bartender should be able to help you out.

Hope this helps.
If your work place is looking to more than printing labels, ie: shipping, receiving, production reporting "live", try RF Express.
 
U

Unregistered

Guest
A few options

Where I work we use 2 label printers form DATAMAX, they have a programming langauge included that it is very well docummented a very easy to implement, you end up using them as any standar printer, Also, I dont use it but I found this sample program that will generate c39 barcode using hp laserjet printers, I found it ont the intenet a while ago so I don't have the original link but I believe it does not have a copyright:

here it is, I hope it Helps:
/*
With thanks to Joern Winther, who first posted this code and made it
available ...

Here's my adaptation of this PEG freeware.

Note: If you use this code and are not a card-carrying Peg member, guilt
will follow you for years and years and years.

Usage:

Define variable input-string as character no-undo initial "001234501".
Define variable bar-code-string as character no-undo.

Run bar-code-39 (input input-string,
input "P030780",
output bar-code-string).

Put control bar-code-string.


*/
/* Create bar-code-stringcode, 39 for HP
** Original code posted on Peg by Joern Winther
** Adapted by Arthur Fink
**
** The procedure creates ESC-sequences for a bar-code-stringcode in
** Code39 format
** The printer cursor position is restored after printing.
**
** Input: input-string as char no-undo. The char string to translate.
** code-spec as char no-undo. The bar-code spec. see later
**
** Output: bar-code-string as char no-undo. The generated bar-code-stringcode
**
**
** Structure of code-spec:
** 1. P for horizontal bar-code
** L for vertical bar-code
** 2-3 width of small bar-codes and spaces in dots (norm 03)
** 4-5 width of wide bar-code and spaces in dots (norm 07-08)
** 6- Height of bar-code in dots (norm 80)
*/

Procedure bar-code-39:

def input parameter input-string as char no-undo.
def input parameter code-spec as char no-undo.
def output parameter bar-code-string as char no-undo.

def var clr as log init true no-undo.
def var wk as char no-undo.
def var drw as char no-undo.
def var dir as char no-undo.
def var k as char no-undo.
def var att as char no-undo.
def var kod as char no-undo
init "1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ.Ï *$/+%".

att =
"100100001001100001101100000000110001100110000001110000000100101100100100"
+ "001100100000110100100001001001001001101001000000011001100011000001011000"
+ "000001101100001100001001100000011100100000011001000011101000010000010011"
+ "100010010001010010000000111100000110001000110000010110110000001011000001"
+ "111000000010010001110010000011010000010000101110000100011000100010010100"
+ "010101000010100010010001010000101010".

def var i as int no-undo.
def var j as int no-undo.
def var l as int no-undo.
def var brd as int no-undo.
def var jst as int no-undo.

assign
i = if substring (code-spec, 1, 1) = "P" then 1 else 2
bar-code-string = "~E&f0S~E*c100G"
drw = substring ("ab", i, 1)
+ substring (code-spec, 6)
+ substring ("ba", i, 1) + "P"
dir = substring ("XY", i, 1)
k = "*" + input-string + "*"
.

do i = 1 to length (k):
assign
j = index (kod, substring (k, i, 1)) * 9 - 8
wk = substring (att, j, 9) + "0"
.
do l = 1 to 10:
assign
brd = if substring(wk,l,1) = "0" then 2 else 4
bar-code-string = bar-code-string
+ (if clr then "~E*c" + substring (code-spec, brd, 2) + drw
else "~E*p+" + string (integer (substring (code-spec, brd, 2))
+ jst) + dir)
jst = integer (substring (code-spec, brd, 2))
clr = not clr
.
end. /* of looping 1 to 10 */
end. /* of going through string 'k' */

assign
bar-code-string = bar-code-string + "~E&f1S"
wk = ""
.
end.


/*
A r t h u r F i n k 10 New Island Avenue
Peaks Island, Maine 04108
· Database solutions using Progress phone & fax: (207) 766-5722
· User interface design and review http://w3.ime.net/~arthur
· Training, mentoring, consulting e-mail: arthur@ime.net

< Peter Headland Actuate training Sept 21-25 in Portland Maine >
 
Hi..

I have tried above barcode program and printed the barcode using hp printer.
It prints the barcode. But that barcode does not get scanned.

waiting for the suggestions...

Thks in advance...
 
/*Solist.p*/

{mfdtitle.i}

def var nbr like so_nbr.
def var nbr1 like so_nbr.
def var llo-PrntBar as lo init yes.
def var llo-pass as lo init yes.
DEFINE VARIABLE lch-PkgCode LIKE code_mstr.code_cmmt.
DEFINE VARIABLE lch-Char2 AS CHARACTER.
DEFINE VARIABLE lch-1PkgBarCode AS CHARACTER FORMAT "X(20000)".
DEFINE VARIABLE lin-Lp AS INTEGER NO-UNDO.
DEFINE VARIABLe lch-ValChar AS CHARACTER
INIT "1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ. *$/+%-" NO-UNDO.


form
skip(2)
nbr colon 20
nbr1 colon 45 skip(2)
with frame a width 80 side-labels.

repeat :

if nbr1 = hi_char then nbr1 = "".

update nbr nbr1 with frame a.

if nbr1 = "" then nbr1 = hi_char.
/* SELECT PRINTER */
{mfselbpr.i "printer" 132}
{mfphead.i}

for each sod_det no-lock where (sod_nbr ge nbr and sod_nbr le nbr1)
break by sod_nbr :
accumulate sod_qty_ord (total by sod_nbr).
if last-of (sod_nbr) then
do:
IF llo-PrntBar THEN DO:
ASSIGN lch-char2 = "P030780".
llo-pass = NO.
lch-pkgcode = substring(sod_nbr,1,20).
DO lin-Lp = 1 TO LENGTH(lch-pkgcode):
IF INDEX(lch-ValChar,SUBSTRING(lch-pkgcode,lin-Lp,1)) <> 0
THEN llo-pass = YES.
ELSE DO: llo-pass = NO.
LEAVE.
END.
END.
IF llo-pass = YES THEN DO:
{gprun.i ""xxprinthpbar.p""
"(lch-PkgCode, lch-char2, output lch-1PkgBarcode)"}
END.
end.
put sod_nbr lch-1PkgBarcode skip(1)
(accum total by sod_nbr sod_qty_ord) skip.

end.


end.
/* REPORT TRAILER */
{mfrtrail.i}




end.
 
/*xxprinthpbar */

/*
** The procedure creates ESC-sequences for a bar-code-stringcode in
** Code39 format
** The printer cursor position is restored after printing.
**
** Input: input-string as char no-undo. The char string to translate.
** code-spec as char no-undo. The bar-code spec. see later
**
** Output: bar-code-string as char no-undo. The generated bar-code-stringcode
**
**
** Structure of code-spec:
** 1. P for horizontal bar-code
** L for vertical bar-code
** 2-3 width of small bar-codes and spaces in dots (norm 03)
** 4-5 width of wide bar-code and spaces in dots (norm 07-08)
** 6- Height of bar-code in dots (norm 80)
*/

def input parameter input-string as char format "x(40)" no-undo.
def input parameter code-spec as char format "x(7)" no-undo.
def output parameter bar-code-string as char format "x(20000)" no-undo.

def var clr as log init true no-undo.
def var wk as char format "x(10)" no-undo.
def var drw as char no-undo.
def var dir as char no-undo.
def var k as char format "x(42)" no-undo.
def var att as char format "x(396)" no-undo.
def var kod as char format "x(44)" no-undo
init "1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ. *$/+%-".

att =
"100100001001100001101100000000110001100110000001110000000100101100100100"
+ "001100100000110100100001001001001001101001000000011001100011000001011000"
+ "000001101100001100001001100000011100100000011001000011101000010000010011"
+ "100010010001010010000000111100000110001000110000010110110000001011000001"
+ "111000000010010001110010000011010000010000101110000100011000100010010100"
+ "010101000010100010010001010000101010010000101".

def var i as int no-undo.
def var j as int no-undo.
def var l as int no-undo.
def var brd as int no-undo.
def var jst as int no-undo.

assign
i = if substring (code-spec, 1, 1) = "P" then 1 else 2
bar-code-string = "~E&f0S~E*c100G"
drw = substring ("ab", i, 1)
+ substring (code-spec, 6)
+ substring ("ba", i, 1) + "P"
dir = substring ("XY", i, 1)
k = "*" + trim(input-string) + "*".

do i = 1 to length (k):
assign
j = index (kod, substring (k, i, 1)) * 9 - 8
wk = substring(att, j, 9) + "0".
do l = 1 to 10:
assign
brd = if substring(wk,l,1) = "0" then 2 else 4
bar-code-string = bar-code-string
+ (if clr then "~E*c" + substring (code-spec, brd, 2) + drw
else "~E*p+" + string (integer (substring (code-spec, brd, 2))
+ jst) + dir)
jst = integer (substring (code-spec, brd, 2))
clr = not clr.
end. /* of looping 1 to 10 */
end. /* of going through string 'k' */
assign
bar-code-string = bar-code-string + "~E&f1S"
wk = "".
 
Thanks for the code kishor...

I used this program to print barcode. It prints the barcode.
But that barcode doesn't get scanned..

Do I need to change anything..
 
Top