I'm converting an RBDOS (2.11?) app to RB 7.6 and having problems printing bar code labels on a DataMax DMXI 4208 label printer. It is a parallel printer hooked up to LPT2.
Instead of printing bar codes and formatted part numbers, it's printing the actual data strings that I'm sending to the printer.
The a portion of the print command in RBase 7.6 looks like:
OUTPUT LPT2
SET LINEEND=(CHAR(13))
WRITE .V2
WRITE .QTYLABEL
WRITE "H13"
WRITE "PO"
WRITE .PEACEN
...
OUTPUT SCREEN
SET LINEEND=(CHAR(þ))
V2, QTYLABEL and PEACEN are previously defined variables, e.g.
SET VAR peacen = ('13110010130020' + (RJS(.qtybatch,4)) & .vpieces)
The '13110010130020' is position, font & other formatting codes that is processed by the DataMax.
What actually prints on the label is:
13110010130020 1 PIECE
The code is straight from the working RBDOS app except I've added the SET LINEEND=(CHAR(13)).
I've compared RBDOS & RB7.6 text files of the output using a hex editor and they are the same.
LPT2 is assigned to the DataMax printer and uses a DataMax driver. It is set up to Spool Print Documents and Start Printing Immediately - I thought that might be messing it up but it works it works for RBDOS and I don't want to muck around and mess up the successful RBDOS printing.
Notice I set LINEEND to (CHAR(13)) and set it back to þ (0254) after outputting to screen
Should the LINEEND be set before the OUTPUT LPT2 statement?
They're running Win XP.
Thanks much,
Doug

