Could use a bit of help here guys! :-)
I'm rather new to the iText API. I've used it so far for automatically
filling in fields with data. I'm now working with a form that has a couple
Checkbox fields. How do I set checkbox fields as checked? I tried using the
setFields method, and passing in the String "true", but that didn't work.
What does the value of the field need to be? Here's a little source code on
what I'm currently doing.
PdfReader reader = new
PdfReader(fileNameIn);
PdfStamper stamper = new PdfStamper(reader,
new FileOutputStream(fileNameOut));
AcroFields form = stamper.getAcroFields();
form.setField("Name","Test Name");
form.setField("odot","123456");
form.setField("Consortium","A Testing Co");
form.setField("PName","My Name");
form.setField("date","10/14/03");
form.setField("Box1","true"); //This is the
checkbox control
stamper.close();
Thanks guys, I appreciate your help.
Chris Howell
Systems Analyst
Oregon Department Of Transportation
Phone (503) 378-4452 Pager (503) 918-1900
[EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>
-------------------------------------------------------
This SF. Net email is sponsored by: GoToMyPC
GoToMyPC is the fast, easy and secure way to access your computer from
any Web browser or wireless device. Click here to Try it Free!
https://www.gotomypc.com/tr/OSDN/AW/Q4_2003/t/g22lp?Target=mm/g22lp.tmpl
_______________________________________________
iText-questions mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/itext-questions