The code on the site should be removed. It should not work at all. 
Page 42 of JSP 1.2 spec:
"Initially, out is a new JspWriter object. This object may be different
from the
stream object returned from response.getWriter(), and may be considered
to be
interposed on the latter in order to implement buffering (see
Section JSP.2.10.1, "The page Directive"). This is the initial out
object. JSP
page authors are prohibited from writing directly to either the
PrintWriter or
OutputStream associated with the ServletResponse."

Tomcat as well as Jrun correctly throw an IllegalStateException. I am
not sure what server is being at iText and why it works there.


Chanan Braunstein
knovel Corp.
Senior Web Developer
607-648-4770 x672
http://www.knovel.com
 
Message: 1
From: "D, Badri Anand (GEAE, GTS India)" <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Date: Thu, 17 Oct 2002 13:10:16 +0530
Subject: [iText-questions] generating PDF from .jsp code

Hi,

I have tried your pdf.jsp code in my local system I get the following
error.

Error: 500
Location: /wls/cmweb/pdfgeneration.jsp
Internal Servlet Error:
java.lang.IllegalStateException: OutputStream is already being used for
this request
        at
org.apache.tomcat.facade.HttpServletResponseFacade.getWriter(HttpServlet
Resp
onseFacade.java:175)
        at
org.apache.jasper.runtime.JspWriterImpl.initOut(JspWriterImpl.java:166)

Can any one help 

is there any working sample code for generating PDF from .jsp

DEV




-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
iText-questions mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/itext-questions

Reply via email to