Copy link to clipboard
Copied
Hello,
How do I use a JavaScript to make 3 text fields requried in order to click a radio button?
In this case, I want to require that someone filles in the "name of person" "phone number" and "task being performed" before they can select the "yes" radio button.
I don't want to make anything invisable or greyed out. Instead, if someone tries to click the "Yes" radio button. I'd like Adobe to prevent them, and give a prompt to fill in the three text boxes required.
Copy link to clipboard
Copied
Hi @Bob_ismyname ,
I hope you're doing well, and thank you for getting in touch. It sounds like you're working on creating a PDF form and want to make certain form fields required. You're on the right track, and I'd be happy to guide you through the process.
How a form field behaves is determined by settings in the Properties dialog box for that individual field. You can set properties that apply formatting, determine how the form field information relates to other form fields, impose limitations on what the user can enter in the form field, trigger custom scripts, and so on.
You can set various properties for an Acrobat form field, depending on the form field type. The properties for each type of form field are selected on a series of tabs. When you change a property, it is applied as soon as you select another property or press Enter.
All types of form fields have a General tab and an Actions tab. Other tabs appear only in specific types of form fields.
Here are the steps you can follow to make a form field required in Adobe Acrobat:
Open the PDF form in Adobe Acrobat.
Go to the "Tools" menu and select "Prepare Form."
Once you're in the "Prepare Form" mode, double-click on the specific form field you want to make required.
In the form field properties dialog box that appears, navigate to the "General" tab.
You should see an option that says " Required." Check this option.
By following these steps, you'll set the selected form field as required, ensuring that users must fill it out before submitting the form.
If you have any more questions or need further assistance with your PDF form or any other related topics, feel free to ask. I'm here to help!
Copy link to clipboard
Copied
Hello Amal, thanks for the response.
Unfortunately, simply making the field required for submittal does not suffice. The 3 fields are ciritcal to this step in the checklist if yes is selected, not the submittal of the form itself.
What we want is a way to prevent the user from selecting the "yes" radio button if they have not filled in the 3 text fields to the left.
If they select N/A, then the fields do not need filled in.
So I need a JavaScript either tied to the 3 text fields that makes the radio button inaccessible.
Or a JavaScript tied to the radio button that references the 3 text fields before becoming available.
Ideally if I tried to click the "yes" radio button, and the text fields were not filled in, then I would receive a prompt telling me to fill in the 3 text fields.
Copy link to clipboard
Copied
Attached is a copy of the form I am creating. the steps in this checklist are steps 2a, 2b, and 2c.
I need a JavaScript that requires
"Name of person crew lead" "Phone number radio channel" "Task being performed"
to all be filled in before someone can select "Group2a" Radio Button Choice "YES"
You'll see in this form that I have some JavaScript that I've already found on Adobe's wonderful forum. But I'm struggling to find anything to acomplish this action.
I appricate the help.
Find more inspiration, events, and resources on the new Adobe Community
Explore Now