Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Obtaining the default printer in VFP6
Message
 
 
To
23/08/2001 09:28:02
Lloyd Grant
Meridian Legal Systems
Buxton, United Kingdom
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Miscellaneous
Thread ID:
00547898
Message ID:
00547900
Views:
8
>I am in the process of coding up a wrapper for the LABEL FORM and REPORT FORM commands. The wrapper is to take care of issues such as previewing reports, erasing the TAG, TAG2 and EXPR fields etc where needed. It will also prompt users for a printer via the GETPRINTER() command. This is all straightforward stuff, but I have one problem. How do I find the current printer that is in use? To my mind there are 2 definitions of this
>
>1) The current windows default printer
>2) The last printer used by VFP
>
>For the purpose of my wrapper I wish to be able to store both of these pieces of information, change if required and restore after the report has been printed / previewed.
>
>Any ideas? I suspect some API wizardry will be called for, but thats something I am not a master of.
>
>Thanks!
? SET("PRINTER", 2)    && Returns default windows printer
? SET("PRINTER", 3)   && Returns default VFP printer
--sb--
Previous
Reply
Map
View

Click here to load this message in the networking platform