Hi Madhu,
I gather you are writing to the response in the action. Does your
action just return a null forward?
I'd start by debugging the page flow to identify where exactly the
problem is located. Make sure the second submit is calling your action
as desired. Then ensure that the JasperRunManager is creating the
desired output and the response has been written to correctly.
If this is a JasperReports issue, you should post a question to a
JasperReports forum.
Kind regards,
Carlin
On 1/28/08, j-re-search <[EMAIL PROTECTED]> wrote:
>
> Hi ,
>
> I am new to jasper reports and I am using them in Java Page Flow in bea
> workshop 9.2
> In one of my action methods
>
> ServletOutputStream servletOutputStream = getResponse().getOutputStream();
>
> InputStream reportStream =
> getServlet().getServletConfig().getServletContext().getResourceAsStream("/classic.jasper");
>
> JasperRunManager.runReportToPdfStream(reportStream, servletOutputStream,
> new HashMap() ,connection);
>
> getResponse().setContentType("application/pdf");
>
> servletOutputStream.flush();
> servletOutputStream.close();
> connection.close();
>
> When I invoke this action method from another page on click of submit , the
> pdf file opens fine for the first time , and then if I click on submit
> again, it fails to open the pdf with the error message ,
>
> There was an error opening this document . This file cannot be found.
>
> Please help me resolve the issue its urgent.
>
> Thanx in advance
> Madhu
> --
> View this message in context:
> http://www.nabble.com/unable-to-open-pdf-usinn-jasper-report-on-bea--workshop--wls-9.2-tp15152880p15152880.html
> Sent from the Beehive - User mailing list archive at Nabble.com.
>
>