Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Printer name from hDC printer handle?
Message
 
To
All
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Title:
Printer name from hDC printer handle?
Miscellaneous
Thread ID:
00931585
Message ID:
00931585
Views:
184
I need to find out the name of the printer that was selected by a user when they print a report.

If I use, REPORT FORM ... TO PRINTER PROMPT, I can't capture the user's printer selection (as far as I know).

If I use the CommonDialog ShowPrinter as in:

loComDialog = newobject( "mscomdlg.commondialog" )
loComDialog.flags = pd_returndc
loComDialog.ShowPrinter()

I get the hDC handle to the printer but how do I use that handle to get a printer name? I have a feeling that it might have to do with the API GetPrinter but I'm stumped at this point.

Any help would be appreciated.

Ed
Next
Reply
Map
View

Click here to load this message in the networking platform