Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Printing from VFOX6.0 to a Dot Matrix Printer
Message
From
23/11/1999 20:27:31
 
 
To
23/11/1999 20:12:59
Bill Totten
William Totten & Associates, Inc.
Indiana, United States
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Miscellaneous
Thread ID:
00293965
Message ID:
00294744
Views:
33
>If I remember correctly, you can kick the printer into "RAW" mode by;
>
>:Stage 1
>SET CONS OFF
>SET DEVICE TO PRINT
>SET PRINT ON
>??? && puts the printer in "raw" mode
>??? escape codes to set page length
>

The problem with this approach lies with Windows and the spooler - it sees the output streams from ??? and the report writer as separate print jobs, and if it's aware of the Windows printer type at either spooler, it'll reset the printer when it switches print jobs. Also, since the two streams are sent separately, someone else's stuff might crawl 'in between' the ??? and the report writer's output, especially since on a network, it isn't safe to start printing output until the whole job is spooled up - the printer may sit idle unnecessarily if the output stream is still open and the pritner finishes doing its thing before the print job completes - very possible with network-attached printers, or printers with larger internal buffers, or both. In this particular case, where we know it's a network printer and two distinct spoolers are involved, it's safer to send the entire, desired print stream to a file and queue that up once the printed output has been generated, so that both the control codes and the output ar seen as a single thing to do that can't get out-of-sync or broken into separate, independent items..

In addition, you do not need to use the SET PRINT/SET CONSOLE combination - ??? sends only to the printer or assigned print file, not the console, whether SET PRINT ON has been done or not.
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform