Crystal Reports quality control...

dreamtime

Active member
Joined
May 13, 2005
Messages
26
Programming Experience
1-3
I need to use the PrintToPrinter method of the Crystal report document object. I am having an issue with quality/resolution control.

I am using CutePDF as a test base (I have performed similar tests on physical printers). I open the report in a CrystalReportViewer and call the crystalreportviewer.printreport using a button. Up pops the print options. I choose 'properties', set the colour to black and white, select 'advanced' and change the resolution to 2400. I then print, in this case, to a PFD file called 'Test A'

Using a second button I invoke the CrystalReport.PrintToPrinter using code similar to below...

Try
'Specify current page settings
PrintDocument1.DefaultPageSettings = PrintPageSettings
PrintDialog1.Document = PrintDocument1

Dim result As DialogResult = PrintDialog1.ShowDialog()

'If click OK, print document to printer
If result = Windows.Forms.DialogResult.OK Then
_template.PrintOptions.PrinterName = PrintDialog1.PrinterSettings.PrinterName
_template.PrintToPrinter(PrintDialog1.PrinterSettings.Copies, PrintDialog1.PrinterSettings.Collate, Me.PrintDialog1.PrinterSettings.FromPage, Me.PrintDialog1.PrinterSettings.ToPage)
End If
Catch ex As Exception
'Display error message
MessageBox.Show(ex.Message)
End Try

I set black and white and a resolution of 2400 and save as a file called 'Test B'

As you probably guess, Test A is b&w @ 2400, Test B is printer default (colour, 600dpi).

Is there any way I can get the PrintToPrinter method to print using the selected quality/resolution, etc? Is my code missing something.

Thank you in advance,
 
Back
Top