Thank you for taking the time to read my question.
I have a simple script in a SharePoint NewForm.aspx which initially hides a field on the form and then displays it if Yes is chosen in response to a question field. Here's the code:
The problem with it is that some of the fields in the form are required fields, and if the user submits the form without completing the required fields, then:
- The field that needs to be completed is highlighted, which I want
- The script above is rerun and the form field is hidden again, which I don't want
How do I prevent the hide script being rerun?
Hoping someone can help.