Am 11.02.2016 um 22:00 schrieb Al Grant:
Hi Gilad,

Just trying to get started with your sample.

Doesnt pdfDocument need to be assigned to the file object in the previous
line?

huh? There is no file object, only a filename.

Tilman


Regards,

-Al


On Fri, Feb 12, 2016 at 2:38 AM, Gilad Denneboom <[email protected]>
wrote:

If the data is located in form fields then PrintTextLocations is not going
to be helpful, but you don't need it.
Accessing form fields using PDFBox is very easy. You can use this code
example to print out the field names and their values to the console:

  PDDocument pdfDocument = PDDocument.load(fileName);
  PDDocumentCatalog docCatalog = pdfDocument.getDocumentCatalog();
  PDAcroForm acroForm = docCatalog.getAcroForm();
  List fields = acroForm.getFields();
  Iterator fieldsIter = fields.iterator();
  while (fieldsIter.hasNext()) {
      PDField field = (PDField) fieldsIter.next();
      System.out.println(field.getPartialName() + ":" + field.getValue());
  }


On Thu, Feb 11, 2016 at 2:32 PM, Al Grant <[email protected]> wrote:

Hello,

I am looking for some help. I am reporting this because I can add some
more
information.

I have a form (a sample of which you can view here :


https://drive.google.com/file/d/0B3rjaapNHpJJa1pfc1l1M2NzSEk/view?usp=sharing
)

Basically the information in the form is tabular. My reading so far tells
me I should using extract text by area and to get those coordinates
printtextlocations.

If any developers out there are able to help, since my coding skills are
rusty I would really appreciate it.

Even if it was just a sample of code for one field which I can then copy
and reuse.

Thanks

-Al


--
"Beat it punk!"
- Clint Eastwood





---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to