Make another field required based on radio button choice - javascript problem
I have no experience of scripting, and I'm creating a form using Acrobat Pro DC. I have a number of sets of radio buttons that, depending on user responses, require other fields to be completed.
I'm stuck on trying to get this to work, despite the community having posted lots of useful scripts for the fields I want user's answers to point to. I used to be able to point to a specific field when I created forms a few years ago using LiveCycle Designer but am obviously missing something about how to get the Run a JavaScript function to work.
I have tried to Add an Action to a radio button option (e.g. the Yes button) using 'Run a JavaScript'
An example is in the Javascript Editor window, I have typed:
if (event.target.value == "Yes")
{this.getField("Employee").required = true;}
What (line detail) do I put in the 'Go to' window that also requires completion?
Any help would be much appreciated.
Many thanks.



