Hi,
I've been working with PDFBox 2.0.4 for a couple of days now.  I've been
successful at merging XFDF data into a form that had been created with
Nuance PDF Converter.  Next I set out to do some work with changing font
size of textboxes based on the amount of text in the textbox field.  As a
basis for that, I've tried to retrieve the textbox value using
getValueAsText after importing the XFDF data.  Nothing comes back.  I've
tried using acrobat to change the value of one of the fields but I still
get null in the value. I've also tried a version created with Acrobat X
Standard.

My next step was to process the PDF file after saving the merged XFDF data
with the PDFBox sample PrintFields.  The textbox values that appear in
Acrobat Reader (after adding setNeedAppearances(true)) do not appear in the
output of PrintFields either.

After a lot of Googling and learning about XFA forms, I added this line to
Printfields to see if my form was XFA.  It isn't.  That line returned
AcroForm
        System.out.println(acroForm.hasXFA() ? "XFA form" : "AcroForm");

As a further thought about XFA, I used one of the IRS forms I have to see
how it behaved.  PrintFields identifies it a an XFA form **and** shows the
textbox values.  The form is f5504ez.pdf.

Any ideas why PrintFields and my own use of getValueAsText isn't working as
expected on a PDF form created with Nuance PDF Converter?  Have any PDFBox
users encountered the same?

I just tried creating form in Acrobat X Standard.  I populated one of its
textboxes with data and then ran it into PrintFields.  The data is included
in the output.  I suppose I could redo the form(s) I plan to use using
Acrobat instead of PDF Creator but the each have many, many fields so that
would be a chore.  I thought I'd ask here first.

Let me know of any details I may have omitted.
Thanks.
Dick

Reply via email to