satyender
satyender

Reputation: 837

How to make Crystal Report print directly to printer without exporting to PDF?

I have a web application in Asp.net which is using Crystal Reports and I am using CrystalReportViewer to show crystal report on my aspx page. When I click on Print Button to Print it show me Message

The viewer must export to PDF to print. Choose the Print option from the PDF reader application once the document is opened. Note: You must have a PDF reader installed to print. (eg. Adobe Reader)

It doesn't Print my report directly . Please help.....

Upvotes: 9

Views: 17311

Answers (1)

Sain Pradeep
Sain Pradeep

Reputation: 3125

Crystal report has PrintToPrinter method to print report direct to printer.

like this

crystalReportDocument.Load("your crystal report file path");
crystalReportDocument.SetDataSource("report data source");
crystalReportDocument.PrintOptions.PrinterName = "your printer name"
crystalReportDocument.PrintToPrinter(1, true, 0, 0);

Upvotes: 8

Related Questions