bthorington wrote: > Hello, > > I've been trying to figure out how to put HTML (converted to PDF) into > form fields in an existing PDF. I have been able to put images and > normal text. > > I can even convert the HTML into its own PDF file (using HTMLWorker.) > Again, I can't see how to load a PDF into a form field on another PDF. > Is this possible??? If it is, could you send me some pseudo code as to > how one might do it?
If you want to prefill the form (and end up with a PDF that still has a form), you're out of luck. If it's your intention to flatten the form, you are very close with HTMLWorker. Instead of using setField(), use getFieldPositions() and use the coordinates you retrieved as boundaries for a ColumnText object. Feed the ColumnText object with the objects obtained with HTMLWorker and go(). -- This answer is provided by 1T3XT BVBA ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ iText-questions mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/itext-questions Do you like iText? Buy the iText book: http://www.1t3xt.com/docs/book.php Or leave a tip: https://tipit.to/itexttipjar
