Re: Printing problems on NT

From: Yar <yarsegal_at_my-deja.com>
Date: Tue, 28 Sep 1999 17:12:02 GMT
Message-ID: <7sqssl$f4b$1_at_nnrp1.deja.com>


In article <bfwO9RBKh373Ewvd_at_ahardy.demon.co.uk>,   Andy Hardy <aph_at_ahardy.demon.co.uk> wrote:
> Hi,
>
> I use TEXT_IO in my Forms4.5 application to write a barcode-printer
> language code to a file which I then print using win_api.winexec and
> the command 'print /d: \\my_machine\my_printer my_file.txt'.
>
> Unfortunately, it is possible for this print routing to be called
> before the printer has finished (or even started, if the printer is
> paused or busy) printing the previous job. I'm getting some
> corruption of the prints, which I think is being caused by
> overwriting the original print file.
>
> Is this possible?
>
> If so, how can I work around this? I don't want to end up with a
> million files one-per-job!
>
> Andy

Hi,

You can easily prevent overwriting files by using unique file names generated by Win_Api_Utility.Generate_Temp_Filename. You can schedule a clean-up on your NT machine at night, so you won't end up with a million files. This is the easiest solution wich comes to mind.

Yar

Sent via Deja.com http://www.deja.com/
Before you buy. Received on Tue Sep 28 1999 - 19:12:02 CEST

Original text of this message