Checkboxes not being marked - RadaeePDF.com
Signin/Signup with: 
Welcome, Guest
Username: Password: Remember me
13 Jul 2017
Microsoft has ended support for Windows Phone 8.1
Read More...
Questions about Android development and PDF
  • Page:
  • 1

TOPIC: Checkboxes not being marked

Checkboxes not being marked 2 years 6 months ago #10566

  • fdelcaz
  • fdelcaz's Avatar Topic Author
  • Offline
  • Junior Boarder
  • Junior Boarder
  • Posts: 21
  • Thank you received: 0
Hi:

I have recently upgraded my license to premium. I´m trying to edit different documents and i have found that checkboxes are not working properly. They arent being highlighted or displaying the typical check mark when touched. I have also noticed that m_annot.GetEditType() returns -1.. What do I have to do?

Thanks

Please Log in or Create an account to join the conversation.

Checkboxes not being marked 2 years 6 months ago #10567

  • Davide
  • Davide's Avatar
  • Offline
  • User is blocked
  • User is blocked
  • Posts: 814
  • Karma: 17
  • Thank you received: 65
Hi,
to perform the check mark you have to tap the checkbox and then tap the "Do button".
This button calls the onAct() method of PDFReaderAct that calls PDFPerformAnnot() that makes the tick.

The m_annot.GetEditType() correctly returns -1 because this annotation is not text-box, you should use m_annot.GetType().
For more info check this : www.radaeepdf.com/documentation/javadocs...ation.html#GetType--
The following user(s) said Thank You: fdelcaz

Please Log in or Create an account to join the conversation.

Checkboxes not being marked 2 years 6 months ago #10569

  • fdelcaz
  • fdelcaz's Avatar Topic Author
  • Offline
  • Junior Boarder
  • Junior Boarder
  • Posts: 21
  • Thank you received: 0
Thanks. I´ve tried with getType() and it returns 20. I need the checkboxes to be marked automatically,, without tapping anything but the checkbox. Is this possible?

Please Log in or Create an account to join the conversation.

Checkboxes not being marked 2 years 6 months ago #10570

  • Davide
  • Davide's Avatar
  • Offline
  • User is blocked
  • User is blocked
  • Posts: 814
  • Karma: 17
  • Thank you received: 65
Hi,
yes, you can move the code from PDFPerformAnnot (PDFReader.java) to the OnClick listener or where you want.

Something like that :
int check = m_annot.GetCheckStatus();
		if( m_doc.CanSave() && check >= 0 )
		{
			switch( check )
			{
			case 0:
				m_annot.SetCheckValue(true);
				break;
			case 1:
				m_annot.SetCheckValue(false);
				break;
			case 2:
			case 3:
				m_annot.SetRadio();
				break;
			}
			m_view.vRenderSync(m_annot_page);
			if( m_listener != null )
				m_listener.OnPageModified(m_annot_page.GetPageNo());
		}
PDFEndAnnot();

Please Log in or Create an account to join the conversation.

  • Page:
  • 1
Powered by Kunena Forum