Sorry, I guess my question wasn't clear...

I'm trying to see if there's a simple change that can be made to the Romeo & Juliet Example that will let you output to a baos instead of to a physical file. If not, I already have the code that reads the PDF into a BAOS and returns it to the browser.

Thanks for your reply.

Thanks.

- M


From: "Iliadis Yannis" <[EMAIL PROTECTED]>
Reply-To: Post all your questions about iText here <[email protected]> To: "Post all your questions about iText here" <[email protected]>
Subject: Re: [iText-questions] BAOS in one step?
Date: Fri, 18 May 2007 15:19:42 +0300

I think what you have to do is:

1) create a web application
2) a jsp page which will trigger the request by calling a servlet
3) a servlet which handles this request and executes an operation (a class
with a createPdf method) and sends the baos back to a jsp page.
4) a class which contains a createPdf method with ByteArrayOutputStream as
return type, where you create the final pdf as a baos instead of a physical
file.

Look also at the following link. It might give you some help.

http://www.theserverside.com/discussions/thread.tss?thread_id=37964



2007/5/18, Jim Hurricane <[EMAIL PROTECTED]>:

I just joined this list yesterday and am not sure my posting made it
online.

I was asking if the basic Romeo & Juliet code example could be modified so
that it writes to a ByteArrayOutputStream directly or if it would be best
to
first write the PDF and then read the PDF into a BAOS and return that?

We're using this code inside a server application so we need to return the
BAOS stream so the browser displays the PDF.

I tried to modify the basic code where you set the writer (using a baos
object instead of a FileOutputStream), but that didn't work.

Look forward to any thoughts or ideas.

Thanks..

-- M

_________________________________________________________________
Catch suspicious messages before you open them—with Windows Live Hotmail.

http://imagine-windowslive.com/hotmail/?locale=en-us&ocid=TXT_TAGHM_migration_HM_mini_protection_0507



-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions
Buy the iText book: http://itext.ugent.be/itext-in-action/




-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/


_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions
Buy the iText book: http://itext.ugent.be/itext-in-action/

_________________________________________________________________
More photos, more messages, more storage—get 2GB with Windows Live Hotmail. http://imagine-windowslive.com/hotmail/?locale=en-us&ocid=TXT_TAGHM_migration_HM_mini_2G_0507


-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions
Buy the iText book: http://itext.ugent.be/itext-in-action/

Reply via email to