RadaeePDF.com :: Topic: The class Annotation: non-working getters (1/2)
Welcome, Guest
Username: Password: Remember me

Signin/Signup with:

Questions about Android development and PDF
  • Page:
  • 1
  • 2

TOPIC: The class Annotation: non-working getters

The class Annotation: non-working getters 2 years 10 months ago #7277

  • Semenovich
  • Semenovich's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 13
  • Karma: 0
I use the methods SetCheckValue() and SetRadio() for editing my PDF form.
switch (element.GetCheckStatus()) {
	case 0:
		element.SetCheckValue(true);
		break;
	case 1:
		element.SetCheckValue(false);
		break;
	case 2:
	case 3:
		element.SetRadio();
		break;
}
mRadaeeView.vRenderSync(page);
mListener.onFormComboButtonClick(page, element);

It works great and radiobox and checkbox buttons updated. But when I call getters for the updated object of Annotation I get illegal values:
@Override
public void onFormComboButtonClick(PDFVPage vPage, Annotation formElement) {
	Log.d(TAG, "onFormComboButtonClick: page #" + vPage.GetPageNo()
			+ ", annotation #" + formElement.GetIndexInPage()
			+ ", selected: " + formElement.GetComboItemSel()
			+ " of " + formElement.GetComboItemCount());
}
09-24 16:09:10.193: D/FormActivity(1061): onFormComboButtonClick: page #0, annotation #-1, selected: -1 of -1

Why the methods GetIndexInPage(), GetComboItemSel() and GetComboItemCount() are not working for me?
The administrator has disabled public write access.

The class Annotation: non-working getters 2 years 10 months ago #7279

  • radaee
  • radaee's Avatar
  • OFFLINE
  • Moderator
  • Posts: 825
  • Thank you received: 10
  • Karma: 43
after set check value or combo value, PDFView refresh the page, Page and Annotation object was not aviable.
you shall re-get annotation object after page refreshed.
The administrator has disabled public write access.
The following user(s) said Thank You: carpinteyroyku

The class Annotation: non-working getters 2 years 10 months ago #7284

  • Semenovich
  • Semenovich's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 13
  • Karma: 0
OK, I remember page number and annotation index before calling SetCheckValue() or SetRadio() methods. Then I get annotation again using these values.

Here is the code.

But the methods GetComboItemSel() and GetComboItemCount() are still not working
09-25 12:00:20.304: D/FormActivity(21368): onFormComboButtonClick: page #2, annotation #27, selected: -1 of -1
Last Edit: 2 years 10 months ago by carpinteyroyku.
The administrator has disabled public write access.

The class Annotation: non-working getters 2 years 10 months ago #7285

  • radaee
  • radaee's Avatar
  • OFFLINE
  • Moderator
  • Posts: 825
  • Thank you received: 10
  • Karma: 43
to be ensure you actived premium license.
if so, you can send me PDF file.
The administrator has disabled public write access.

The class Annotation: non-working getters 2 years 10 months ago #7286

  • radaee
  • radaee's Avatar
  • OFFLINE
  • Moderator
  • Posts: 825
  • Thank you received: 10
  • Karma: 43
oh, sorry, radio and check-box has no combo items.
combobox is a dropdown list box, and users can select 1 item to change text value.
Last Edit: 2 years 10 months ago by .
The administrator has disabled public write access.

The class Annotation: non-working getters 2 years 10 months ago #7288

  • Semenovich
  • Semenovich's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 13
  • Karma: 0
Hmm... Nevertheless can I get the selected radiobox position?
The administrator has disabled public write access.
  • Page:
  • 1
  • 2
Powered by Kunena Forum