Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Running a DOS-style invoice-printing prg in VFP
Message
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Miscellaneous
Thread ID:
00612614
Message ID:
00612647
Views:
21
Hi Rich,

You can print to a file instead and than send the file directly to the printer queue using file #1069 or file #9957.

>I've nearly finished a conversion from 2.6 DOS to VFP. It was supposed to be middle of the road between "quick and dirty" and full-blown re-write. The idea was to use VFP forms to make the main data-entry forms pretty, but keep the "procedural" code as unchanged as possible. (More on that in another message.)
>
>This is one of the remaining problems:
>
>The invoices are printed by an old (almost unchanged) PRG, on pre-printed tractor-fed dot-matrix forms. This code, when run in Fox 2.6 in a command prompt window on a WinME computer, prints the invoice as expected. The same code, run in VFP on the same computer, prints in a different font and is mis-aligned.
>
>The code is an old-fashioned
SET DEVICE TO PRINT
>DO WHILE NOT EOF()
>    ? and ?? commands
>ENDDO
>SET DEVICE TO SCREEN
arrangement.
>
>The Windows printer settings are Don't Spool anything (DOS or Windows), Print in Raw format. Still, VFP seems to be forcing some unwanted printer driver behavior. Is there some setting to tell VFP to send raw data to the printer? If it's going to be as much work as changing all the ?'s and ??'s to ???'s, and adding CHR(13)s as needed, I guess I may as well make an FRX. For that matter, an FRX might not have taken as long as composing this message! <g>
>
>TIA,
>Rich Addison
--sb--
Previous
Reply
Map
View

Click here to load this message in the networking platform