Welcome Dialog

Welcome to the Community!

We have a brand new look! Take a tour with us and explore the latest updates on Adobe Support Community.


Select a Radio button Based on another Field

New Here ,
Aug 27, 2021 Aug 27, 2021

Copy link to clipboard

Copied

Hello. I am looking to have a field filled in with a line of text. Based on the respose given in that field have a radio button checked. For example If "Field 1" has "Before" or "After" in it, it will select "Group 1" > "Selection 1" marked, If "Field 1" has "No" in it, it will select "Group 1" > "Selection 2" Marked. I know how to do this with a check box, but not a radio button. 

 

this.getField("Check Box 1").checkThisBox(0, event.value=="Answer 1");

 

 

TOPICS
How to, JavaScript, PDF forms

Views

32

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
community guidelines

correct answers 1 Correct answer

Adobe Community Professional , Aug 27, 2021 Aug 27, 2021
You can use like this at text field validation: if( event.value == "Answer 1")this.getField("Group1").value = "Choice1"; Change radio button name and choices in script to your actual names.

Likes

Translate

Translate
Adobe Community Professional ,
Aug 27, 2021 Aug 27, 2021

Copy link to clipboard

Copied

You can use like this at text field validation:

if( event.value == "Answer 1")this.getField("Group1").value = "Choice1";

Change radio button name and choices in script to your actual names.

 

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
community guidelines
Adobe Community Professional ,
Aug 27, 2021 Aug 27, 2021

Copy link to clipboard

Copied

Do you want to check for the exact values "Before" or "After", or if they appear anywhere in the text?

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
community guidelines
New Here ,
Aug 27, 2021 Aug 27, 2021

Copy link to clipboard

Copied

LATEST

Long story, but I will try to be brief. Our office people are using a site that has several drop down menues and text fields they are filling in. The Form is uploaded on the site and fields are being filled in based on there responses. I then DL the form, and have to fill out the rest. I can not change the way the form looks (IE changing the radio buttons to a text field or drop down), so I am creating text fields that are hidden to fill in radio and check boxes. I am able to modify the site so when I am using it to trigger a box or radiom that it is a drop down so it will be exact. Most of the Text fields are things like permit no. that are not triggering anything just filling in the box. 

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
community guidelines