Click here to Skip to main content
15,884,986 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello,
I need to find PrinterResolution.Kind of a document whis is been sent to printer.
Actually my aim is to Allow admin to catch all the Print which are being printer in High Resolution.

I googled and found System.Drawing.Printing.PrinterSettings.PrinterResolution will help me.

But how can i Find the PrintResolution of Spooled Document?

Prathamesh
Posted

1 solution

What you really need to know in most cases is not a printer resolution (is does not really effect the printing from the standpoint of your printing code; is you have two print pages with the same sizes in pixels but different resolutions, the print data to be send is exactly the same).

If you are using System.Drawing.Printing you will ultimately use the class System.Drawing.Printing.PrintDocument. If you use this class for printing :-), you will have to handle the event System.Drawing.Printing.PrintDocument.PrintPage, and event arguments of this event will pass the required information in its properties MarginBounds, PageBounds, as well as PageSettings to you handler.

Please see:
http://msdn.microsoft.com/en-us/library/system.drawing.printing.printdocument.aspx[^],
http://msdn.microsoft.com/en-us/library/system.drawing.printing.printdocument.printpage.aspx[^],
http://msdn.microsoft.com/en-us/library/system.drawing.printing.printpageeventargs.aspx[^].

—SA
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900