From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 1164f8,da236cf0cbd1bca6 X-Google-Attributes: gid1164f8,public From: Alan Adams Subject: Re: Capturing a print queue Date: 1998/12/24 Message-ID: <36829F1A.608D@gecm.com>#1/1 X-Deja-AN: 425487972 Content-Transfer-Encoding: 7bit References: Content-Type: text/plain; charset=us-ascii Organization: GEC Marconi Materials Technology Mime-Version: 1.0 Newsgroups: comp.sys.dec Richard wrote: > > Hi, > > We run a pharmacy system that is unable to produce its standard reports > in a csv format which to be honest is a pain! > > The software prints using the print queues on an alpha and it has > occurred to me that I could probably install a backend on the print > queue that could manipulate the output from the software (text) and dump > it into a file as csv rather than to a printer. > Dirty solution: Make sure the queue is never started. Using F$GETQUI from DCL you can find out the file name of the temporary file, then copy the file, delete the entry from the queue, and do your own thing with the file. Same works from compiled code, use SYS$GETQUI. GETQUI is probably the most complex system service interface in VMS. The HELP examples are useful in DCL, and it's wirth playing with the DCL version before trying the SYS version, which is even worse. However, step by step, persistence, and patience produce results. All this assumes a text printer. Postscript or PCL would be a pain. (Valium might be useful too.) -- Alan Adams