Option for conditional 'only able to check one' box?

Explorer ,
Jun 19, 2019

Copy link to clipboard

Copied

Hi,

Creating a form that asks an 'either or' type of question, and I'd like to be able to limit the user to check only one box. Is there a way to make the other box unavailable if the first is checked, but yet they can still change their mind choose the other (in the case of mistakenly checking one), it just unchecks the other box. I shared a snip below for context. Hopefully that makes sense. Thank you!

V

Most Valuable Participant
Correct answer by try67 | Most Valuable Participant

Simply give both fields the same name but different export values. No scripts required.

TOPICS
Acrobat SDK and JavaScript, Windows

Views

270

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

Option for conditional 'only able to check one' box?

Explorer ,
Jun 19, 2019

Copy link to clipboard

Copied

Hi,

Creating a form that asks an 'either or' type of question, and I'd like to be able to limit the user to check only one box. Is there a way to make the other box unavailable if the first is checked, but yet they can still change their mind choose the other (in the case of mistakenly checking one), it just unchecks the other box. I shared a snip below for context. Hopefully that makes sense. Thank you!

V

Most Valuable Participant
Correct answer by try67 | Most Valuable Participant

Simply give both fields the same name but different export values. No scripts required.

TOPICS
Acrobat SDK and JavaScript, Windows

Views

271

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Jun 19, 2019 0
Adobe Employee ,
Jun 20, 2019

Copy link to clipboard

Copied

Hi valeriecarina,

Creating a form that asks an 'either or' type of question, and I'd like to be able to limit the user to check only one box. Is there a way to make the other box unavailable if the first is checked, but yet they can still change their mind choose the other (in the case of mistakenly checking one), it just unchecks the other box. I shared a snip below for context. Hopefully that makes sense. Thank

Yes, this is possible. You will need to use Acrobat JavaScript to apply conditions on field. We do not have expertise is scripting, but our JavaScript experts here JavaScript  will look into this and help you accordingly.

Thanks,

Akanchha

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jun 20, 2019 0
Most Valuable Participant ,
Jun 20, 2019

Copy link to clipboard

Copied

Simply give both fields the same name but different export values. No scripts required.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jun 20, 2019 2
Adobe Community Professional ,
Jun 20, 2019

Copy link to clipboard

Copied

You give each box the same name and then open the properties for each field and give each field a unique export value.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jun 20, 2019 2
Community Beginner ,
Jun 20, 2019

Copy link to clipboard

Copied

What would you consider a unique export value?

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jun 20, 2019 0
Adobe Community Professional ,
Jun 20, 2019

Copy link to clipboard

Copied

You can set the other checkbox as read only.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jun 20, 2019 2
Explorer ,
Jun 20, 2019

Copy link to clipboard

Copied

Thanks everyone for all the suggestions! I made the fields the same name, and then changed the export value for the specific fields to their "question." Appreciate the help!


V

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jun 20, 2019 2
Community Beginner ,
Jun 20, 2019

Copy link to clipboard

Copied

Thank you as well - I've also learnt something new!!!!

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jun 20, 2019 1