Printer Output to file (AREV Specific)
At 08 JUN 1999 09:27:36AM Jeff Morra wrote:
Does anyone know a simple way to output all printing from RBASIC code to a file instead of the LPT port? We are using ver 3.12.
At 08 JUN 1999 10:00AM Jeff Morra wrote:
Just a few moments after writing this, I found the PDISK command which does exactly what I want.
At 08 JUN 1999 10:15AM Michael Slack wrote:
PDISK and PRINTER are the two commands you want to redirect your output to a file instead of a printer. For the PDISK line you'll need the path and file name with its extention. The path and file name can be hard coded or in a variable. Try something like this:
program code
PERFORM 'PDISK C:\OUTPUT.TXT'
PRINTER ON
program code
PRINTER OFF
PERFORM 'PDISK PRN'
You'll use PRINT statements to get your data to the file. If at any time you need to print something out to the screen using a PRINT statement you can do:
PRINTER OFF
PRINT statement to go to the screen
PRINTER ON
But I would suggest that you use a message statement if at all possible. It's just simpler.
I hope this helps.
Michael Slack
At 08 JUN 1999 05:01PM Steve Smith wrote:
Apart from PDISK, there have been occasions where I have used a PC magazine utility called prn2file.com and also Novell's capture command - these too do what you require, and can be useful to trap printer output from EXE's called by AREV.
Steve