I would like to show the printing preferences dialog box for the default printer from within my application. I'm guessing its going to be an API call, but for the life of me I can't find any info on this subject. Any one got a clue for me ??
won't the dialog box control do for asking the printing options? thru project/components add microsoft common dialog contol 6.0 to your project. now, from the toolbox, add it to your form. and put a command control also on your form. in the click event of your command button, add this code, (dialog box control is named dialog1)
dialog1.showprinter
will the dialog box that comes up do for your purpose?
Thanks for the replies guys, I'll check out your link ca8msm. teresachristy, I am using VB reports, so printer page size has to be set to the report size before the report is shown. VB reports totally ignores anything set by printer.papersize and the common dialog control.
I've just followed up on your link ca8msm, its a 'nearly there' situation. The examples refuse to show the properties for my Lexmark, which is a pretty jazzy properties box, and only shows a single tab for my more standard Canon, more research required. It is definitely the PrinterProperties API call tho, I think, maybe...
If all the "extra" details to a specific printer do not show up you may have to include a reference to one of the DLL's for that printer. I remember on one of my old Canon's I only got a basic setup using the API, whereas if I used the Canon's DLL's I got all the options that was available in the actual canon software.
That sounds reasonable ca8msm, the Microsoft Support Knowledge Base even mentions that not all tabs may be visible using PrinterProperties, no clues other than that tho. I'll look into using the DLL's for the printer, thanks for the lead.
this works fine, the /e displays printing preferences, and the /n is followed by the printer name, Printer.DeviceName being the default printer name, one problem tho, it will not work when the printer name has spaces in it, anyone got any further ideas??
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.