Hello, I am new to this form creating and having to create a simple form with all yes & no responses, however after creating the drop down fields I get lost on the java script ( way over my head) I want to create a if/then statement in Acrobat. If they answer yes, additional comments must me answered. If no, then no additional questions are needed.
So you want to make a field hidden or visible based on the selection in the drop-down, basically?
Hi, It does not have to be hidden, Working on a questionnaire set up with yes / no answers on a drop downs . I wanted to require people to comment if they selected Yes on drop down. Sorry I am so new to this, the creating part of the form was pretty user friendly for starters like me, but the java script is a bit overwhelming after reading / seeing some tutorials,
Then you need to define what "require" means. In what way should it be required? How should it be enforced?
Is the file being submitted back to you? If so, you can set the field's "required" property to prevent it from being submitted.
By require I meant, If they answer yes on any of the questions, they will need to answer why they said yes in a additional comment field that I need to set as required to fill out.
That doesn't answer my question, so let me rephrase: What should happen if they don't fill in that additional comments field?
sorry, if they dont fill out tha additional field it will not let them submit the form.
OK. In order to do that you need to set the field as required.
As the custom calculation script of the comments field you can enter something like this:
event.target.readonly = (this.getField("Dropdown1").valueAsString=="Yes");