Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

Troubleshooting
Research
Professional Opinions
Ask a Question
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE

troubleshooting Question

Crystal Report Viewer - Export to/open a PDF after entering parameters

Avatar of synapse88
synapse88 asked on
Crystal ReportsC#ASP.NET
2 Comments1 Solution927 ViewsLast Modified:
I have a report viewer in place, and i would like the report in question to be opened in a PDF after the user enters parameters and clicks the submit button (instead of the report being opened in the report viewer window.)

I did some reading elsewhere and found this snippet

rptSP.ExportToHttpResponse(ExportFormatType.PortableDocFormat, Response, true, "Report");

and i also found a posting where the following was recommended:

Write code to export the report to pdf inside of the CrystalReportViewer_BeforeRenderObject event.

but I haven't made it much past that. Can anyone provide a code example, or link to one which shows this solution in place?