Print Page | Close Window

How to display PDF print preview screen?

Printed From: Crystal Reports Book
Category: Crystal Reports for Visual Studio 2005 and Newer
Forum Name: Report Design
Forum Discription: The best way to design a report and problems you have encountered
URL: http://www.crystalreportsbook.com/forum/forum_posts.asp?TID=9854
Printed Date: 20 Sep 2024 at 3:05pm


Topic: How to display PDF print preview screen?
Posted By: momer79
Subject: How to display PDF print preview screen?
Date Posted: 29 Apr 2010 at 1:11am

Hi,

I have question regarding printer option page which pop up when i click on print button on crystalreportviewer  and when i click okay on that pop up page it displays print preview of the report.

Is there any way to skip that pop up window(Printer Option) and just display (PDF)print preview screen instead?

(I am not exporting report to pdf, just want to display printview screen and when the user click on print button it will print out the page)

I have tried following code but i am getting error:

"Object reference not set to an instance of an object."

-------------------------------

myRpt = New ReportDocument

myRpt.Load(Server.MapPath("../Reports/myreport.rpt"))

myRpt.ExportToHttpResponse(ExportFormatType.PortableDocFormat, Response, True, "")

--------------------------------

Any solution pls?




Print Page | Close Window