uncheck all radio

Forum for the PDF-XChange Editor - Free and Licensed Versions

Moderators: TrackerSupp-Daniel, Tracker Support, Paul - Tracker Supp, Vasyl-Tracker Dev Team, Chris - Tracker Supp, Sean - Tracker, Ivan - Tracker Software, Tracker Supp-Stefan

Post Reply
Sebastien_B
User
Posts: 14
Joined: Thu Jul 09, 2020 8:38 pm

uncheck all radio

Post by Sebastien_B »

Hello

how to make so that all the radio of a group are unchecked by default?

thank you
User avatar
TrackerSupp-Daniel
Site Admin
Posts: 8440
Joined: Wed Jan 03, 2018 6:52 pm

Re: uncheck all radio

Post by TrackerSupp-Daniel »

Hi, Sebastien_B

Radio buttons, when placed, will be unchecked. If you have mistakenly checked one of them, the only way to clear it is to reset the form:
image.png
So long as you have not specified for any one field to be "checked by default", this will work. If you have, simply disable that function from the properties pane (Ctrl+~) while the filed is selected with the "select fields" tool.

Kind regards,
Dan McIntyre - Support Technician
Tracker Software Products (Canada) LTD

+++++++++++++++++++++++++++++++++++
Our Web site domain and email address has changed as of 26/10/2023.
https://www.pdf-xchange.com
Support@pdf-xchange.com
fletch
User
Posts: 79
Joined: Wed Mar 11, 2020 2:53 am

Re: uncheck all radio

Post by fletch »

What if I'm filling in a form I received from someone and accidently checked a button/field. But I've also spent the past 30 minutes filling in the remainder of the form before noticing that? I don't want to start from scratch!
User avatar
Tracker Supp-Stefan
Site Admin
Posts: 17824
Joined: Mon Jan 12, 2009 8:07 am
Location: London
Contact:

Re: uncheck all radio

Post by Tracker Supp-Stefan »

Hello fletch,

In that case - just select the relevant radio button option from the available ones provided by the form creator.
Ideally there should be an "none of the above" kind of radio option, if that radio group does not require a mandatory selection in the form you are filing in.

Kind regards,
Stefan
fletch
User
Posts: 79
Joined: Wed Mar 11, 2020 2:53 am

Re: uncheck all radio

Post by fletch »

Yeah, that's the problem, poor form design. There are 3 radio buttons. I clicked one. Then realized the "section" those radio buttons were in did not apply. So NONE of the radio buttons were applicable and 'none of the above' was not an option. To make things worse, I had filled in ALLOT of fields on the form so resetting ALL of them is just not ideal. Seems that no PDF tools have a solution for this - perhaps due to design restrictions in the PDF format.
User avatar
Tracker Supp-Stefan
Site Admin
Posts: 17824
Joined: Mon Jan 12, 2009 8:07 am
Location: London
Contact:

Re: uncheck all radio

Post by Tracker Supp-Stefan »

Hello fletch,

Just spent some time reading the JS API specification, and you can actually call a single line JS code:

Code: Select all

this.resetForm("Group1"); 
to reset only a specific field and not the whole form. The "Group1" should be changed to the name of your particular radio button group name.

You can open the JS console in the Editor with the Ctrl + J key combination.

Kind regards,
Stefan
fletch
User
Posts: 79
Joined: Wed Mar 11, 2020 2:53 am

Re: uncheck all radio

Post by fletch »

Genius :D Saving this tip for future.

Thank you!
User avatar
Tracker Supp-Stefan
Site Admin
Posts: 17824
Joined: Mon Jan 12, 2009 8:07 am
Location: London
Contact:

uncheck all radio

Post by Tracker Supp-Stefan »

:)
Post Reply