Creating an Error Message in Client Script
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-18-2017 01:18 PM
I'm a novice in JS so I'm having some difficulty making a client script to make an error message on the Demand form to tell the user they need to answer a question in a choice field before continuing if the "portfolio" field contains a value of "AIT." Any suggestions would be very appreciated! At this point I have not found a suitable script to tweak for my purpose, but I do know I probably need to use "getErrorMessage." Thanks!
- Labels:
-
Scripting and Coding

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-18-2017 01:23 PM
You can use alert() message or g_form.addErrorMessage(message). When do you want this error message to be displayed? When user submits the form?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-18-2017 01:33 PM
So the "portfolio" field is going to populated after being submitted, so the error message needs to display after it's submitted and the field is populated. I want to use the addErrorMessage. Do you have a script that would work that you could show me? It needs to be based on the "portfolio" being "AIT" and the Yes/No question not already answered.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-18-2017 01:38 PM
So you basically want this check when the form loads and portfolio" being "AIT" and the Yes/No question not already answered right?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-18-2017 01:39 PM
Yes that is correct.