You are flattening the file with stamp.setFormFlattening(true). This eliminates all the fields and only keeps the appearances. Eliminate that line to keep the fields.
Best Regards, Paulo Soares > -----Original Message----- > From: Lei, The-Viet [SMTP:[EMAIL PROTECTED] > Sent: Wednesday, March 12, 2003 13:43 > To: '[EMAIL PROTECTED]' > Subject: [iText-questions] why are the text fields not editable any > more after using PdfStam per to merge the fields ? > > Hello power users of iText, > > > I use the following method to merge text fields. The side effect is that > the > text fields are not editable any more in the acrobat reader 5.1. > Does any body know why and how to avoid that? > > Thank you for your reading and help, > > Best regards The-Viet Lai > > > > public static void mergeFields(File inPdf, File outPdf, HashMap fields) > throws Exception > { > OutputStream os = new FileOutputStream(outPdf); > PdfReader reader = new PdfReader(inPdf.getAbsolutePath()); > PdfStamper stamp = new PdfStamper(reader, os); > AcroFields form = stamp.getAcroFields(); > HashMap pdfFields = form.getFields(); > Iterator it = pdfFields.keySet().iterator(); > while (it.hasNext()) > { > String field = (String)it.next(); > String value = (String)fields.get(field); > form.setField(field, value); > } > stamp.setFormFlattening(true); > stamp.close(); > os.close(); > } > > > > > > > ------------------------------------------------------- > This SF.net email is sponsored by:Crypto Challenge is now open! > Get cracking and register here for some mind boggling fun and > the chance of winning an Apple iPod: > http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0031en > _______________________________________________ > iText-questions mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/itext-questions ------------------------------------------------------- This SF.net email is sponsored by:Crypto Challenge is now open! Get cracking and register here for some mind boggling fun and the chance of winning an Apple iPod: http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0031en _______________________________________________ iText-questions mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/itext-questions