Copy link to clipboard
I have a form I am creating where we ask for them to chose between 3 options.
There are 2 of those 3 seelctions that would need to trigger a text box beneith to be required.
I have the 3 selections setup as radial buttons already and attempted to use the following code but it would only wok for 1 of the 2 not either or.
event.target.required=(this.getField("Requests").valueAsString=="Create and Login");
Using this within the Custom Calculation Script, would only trigger the required field from Create and Login but not Login Project.
Hope this all makes sense.
The second line overrides the setting of the first line.
Is there a way to make it an either/or thing? Without it overriding one another?
You can use this:
event.target.required = this.getField("Requests").valueAsString == "Login Project" || this.getField("Requests").valueAsString == "Create and Login";