Page 1 of 1

ResponseAsPdf (FireFox)

Posted: Thu Aug 29, 2013 6:37 pm
by ToneCold
I am using Stimulsoft.Report.Web.StiReportResponse.ResponseAsPdf, it works great, but in FireFox the download button saves the pagename.aspx instead of .pdf.

Is there a way to fix this? Other browsers seem to work fine. The "type" in the pdf page source says "application/pdf" and right-clicking on the page and selecting "Save Page As" does work.

Thanks for your help (Stimulsoft Version 2013.1).

Tony

Re: ResponseAsPdf (FireFox)

Posted: Fri Aug 30, 2013 6:54 am
by Vladimir
Hello,

To display the save dialog, you must call the method as follows:
StiReportResponse.ResponseAsPdf(Page, report, true);

Also, we recommend to use the latest pre-release version available on our website. We tested the method on Firefox 23.0.1, works correctly.

Thank you.

Re: ResponseAsPdf (FireFox)

Posted: Fri Aug 30, 2013 6:24 pm
by ToneCold
Due to a work-around of a different issue I have to show the pdf. But I was able to find a fix:

Response.AddHeader("Content-Disposition", "inline; filename=FileName.pdf \ ")

Adding the above line before:
StiReportResponse.ResponseAsPdf(Page, report, true);

Fixes the issue in FireFox.

Tony

Re: ResponseAsPdf (FireFox)

Posted: Mon Sep 02, 2013 6:01 am
by Alex K.
Hello,

Thank you for the information.