Microsoft Windows Phone 8.1 support ends (13 Jul 2017)

Microsoft has ended support for Windows Phone 8.1

Questions about Android development and PDF

Compiling PDF forms

More
IP: 192.168.0.71 12 years 3 months ago #6451 by noberasco
Hi,

I'm currently investigating whether this library is suitable for one of our applications.
Basically, we need to:
1) allow users to view and compile PDF forms
2) determine which fields have been compiled and which have not
3) programmatically extract values for compiled fields and store them in a data base
4) export compiled PDF

So far I'm playing with the library to achieve 1, but I'm getting mixed results.
I have been able to fill in text boxes, combo boxes and check boxes implementing PDFAnnotListener interface.

What about other field types (radio buttons, image fields, ...)? I don't seem to see support for them in PDFAnnotListener interface... Is PDFAnnotListener the only way to go, or other approaches are feasible?

Any suggestions are welcome.

Regards
Michele
More
IP: 192.168.0.158 12 years 3 months ago #6452 by nermeen
Replied by nermeen on topic Compiling PDF forms
The SDK supports all the features you need..

But you need to use the classes under com.radaee.view instead of com.radaee.pdfex (deprecated)
You need to imoplement the listener: PDFReaderListener
in OnAnnotClicked(PDFVPage, Annotation) you can call: m_reader.PDFPerformAnnot

when you check PDFReader.PDFPerformAnnot you will find that it handles the different annotations type (including checkbox, radio buttons)
For editbox and combobox...they are handled in PDFReader.OnPDFSingleTapped(float, float)
More
IP: 192.168.0.71 12 years 3 months ago #6462 by noberasco
Replied by noberasco on topic Compiling PDF forms
Hi nermeen,

thank you for your reply.

I successfully changed my implementation to use PDFReaderListener instead of deprecated code.
I also managed to edit several form field types.

However, I'm still not able to edit radio buttons.

In every test PDF I tried, when calling GetCheckStatus() on a radio button I get value -1 (invalid control) instead of the expected values 2 or 3. As you can expect, calling PDFPerformAnnot() or SetRadio() on this annotations produce no effect.

Regards,
Michele
More
IP: 192.168.0.158 12 years 3 months ago #6463 by nermeen
Replied by nermeen on topic Compiling PDF forms
The radio button requires the premium license...
If you are using the demo project it should work as it's already activated with a premium license...

if you are using your project and you don't have the license yet, you need to give your project "com.radaee.reader" as package name. (Eclipse:Right click you project -> Android Tools -> Rename Application package)


www.androidpdf.mobi/documentation/javado...tion.html#SetRadio()
More
IP: 192.168.0.71 12 years 3 months ago #6465 by noberasco
Replied by noberasco on topic Compiling PDF forms
Hi,

I'm testing using package name "com.radaee.reader" and premium license is active.
In fact, other premium-only methods such as GetComboItem() or GetFieldType() do work as expected.

Also, the PDF files I tried are valid, and for instance I can edit the radio buttons in there using other software such as Adobe Reader.

Another question, are image fields supported?
Documentation for GetFieldType() does not mention them, and indeed I get 0 (unknown) when I select an image field.

My feeling is that either the documentation is missing some information, or the library only supports a subset of field types.

Regards,
Michele
More
IP: 192.168.0.158 12 years 3 months ago - 12 years 3 months ago #6468 by nermeen
Replied by nermeen on topic Compiling PDF forms
Can you send us a sample pdf with radio buttons and image fields...

You can attach it here, or send to [email protected]
Last edit: 12 years 3 months ago by marcoP.
Time to create page: 0.430 seconds
Powered by Kunena Forum