views:

314

answers:

1

i've managed to create a template (for an invoice) in livecycle. i've choosed dynamic pdf instead of static pdf because of a few fields that needed to autoresize (like address, product name). now i use itextsharp to complete the fields, and it works if i save the pdf as acrobat 7 dynamic xml form. the problem is that the fields are editable. in order to resolve this in itextsharp i have to put formflattening = true, but then when i open my pdf i can't see anymore the whole address for example, or the full text that made the field to expand.

has anyone an ideea how to make the pdf non-editable after i've set the fields? if i use adobe reader pro to build the fields, they don't expand in order to accomodate the full lengh of the text.

A: 

can u send me ur itextsharp code, i have a problem filling in my form and i cant figure out why...

val
here you go:PdfStamper pdfStamper = new PdfStamper(reader, new FileStream(string.Format(pdfFolder, fileStampped), FileMode.Create)); AcroFields pdfFormFields = pdfStamper.AcroFields; // set form pdfFormFields pdfFormFields.SetField("Seller_Name", "company name"); pdfStamper.FormFlattening = true; pdfStamper.Close();
This is not an answer, it should be as comment at most
DixonD