Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

working with pdf.... in java j2ee

 
vijaykumar shah
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is two in one question ...

i already have a Java program using FO in XSL that generated pdf as o/p file in the browser..... now i want to save that file on hard disk .. how can i save it .. is there any api for saving the pdf file.... as we have for generating pdf files


secondly .. how do we append two pdf files in java ... i am using jdk1.3 , weblogic . I need api .. pure java program to append the pdf files

vijay
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 34389
346
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Vijay,
i already have a Java program using FO in XSL that generated pdf as o/p file in the browser..... now i want to save that file on hard disk .. how can i save it .. is there any api for saving the pdf file.... as we have for generating pdf files

Are you trying to write it to disk on the server or client?
If the server: The PDF file is written to a stream. Just write that stream to a location on disk.
If the client: Set the type to attachment. The user will be prompted to select a download location.

secondly .. how do we append two pdf files in java ... i am using jdk1.3 , weblogic . I need api .. pure java program to append the pdf files

I think you will need a commercial API for that. The free ones don't seem to read in PDF.
 
Ashish Vegaraju
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

For appending pdf files....u can use Lowagie's iText Java APIs.
log on to www.lowagie.com/iText

Any info on format convertion feel free to ask.
Ashish.
 
vijaykumar shah
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You got me very right .. and u suggested right answer . i have worked in the same fashion and i got the results what i needed..

Thanks

Vijay
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic