- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-27-2017 10:21 AM
Hi All,
How to I catch the invalid reference in reference fields, ex. I have three condition to put in on reference field,
1. I need to populate related information when the value exists in reference table -Good with it.
2. Onchange of the field if no value is selected which means the value is null, I need to take some action - Good with it.
Finally comes with the 3rd action which I'm not able to track, 3. If i enter some junk value in reference field and which is not exists in reference table as shown below,
then, I need to alert the user saying that the value doesn't exists. How can I achieve this. Please let me know if anyone is having answer for it.
I referred one of community links "Need to add an alert when there is an Invalid Reference in a Reference field " which says get the value of form for particular field and if I did so, the alert is getting populated twice with null value for third condition.
Thanks,
Sowmya
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-27-2017 11:16 AM
Hi Sowmya,
Entering wrong value is making the field RED, that it self is an indication that the value is wrong and even when submit the form that system will not save the invalid data. So i think there is no need for a client script for validation since its not accepted.
You can make the field mandatory so that it wouldn't be allowed to submit the form without entering the value.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-28-2017 06:03 AM
Based on your requirements, I recommend what Shishir has proposed also.
You cannot detect an invalid entry with a client script or UI policy (to show/hide fields). You need to have a proper/valid value with which to do that. "Other" or "Not found" seems like the logical choice - or a separate true/false checkbox that indicates "I couldn't find my value in the list". If they check that, the reference field is hidden and the text field is displayed.