UI Plocy is not working
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-10-2024 12:29 AM
Hi Team ,
under closure information , I have created 2 custom fields . please check screenshot .
when we click on ' COMPLETE' or States changes to ' closed ' these two custom become mandatory .
I have created UI Policy for this ,
in the when to apply > CHANGES , option is not there .
But it is not working
can anyone please help me here ... what was the mistake here . please provide steps .
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-10-2024 01:12 AM
Hello @nameisnani ,
Can you please try using script option on UI policy with below script -
function onCondition() {
g_form.setMandatory('u_city', true); //replace variable name
g_form.setMandatory('caused_by', true);
}
If my answer solves your issue, please mark it as Accepted and Helpful based on the impact.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-10-2024 02:00 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-10-2024 01:50 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-12-2024 03:17 AM
Can you stop posting the same questions several times. People are giving you the same answers others have already given, without them knowing what you did or didn't try. You are not just wasting your own time and will loose track of the answers, but also of the people that are spending their own time to help you.
If for any reason you want to post the exact same question again, because you aren't getting anywhere, close the previous one and add the already given (not working) solutions to the new question so there is a clear overview of what already was done.
https://www.servicenow.com/community/developer-forum/facing-issue-with-ui-policy/td-p/2985667
https://www.servicenow.com/community/developer-forum/ui-plocy-is-not-working/td-p/2985805
https://www.servicenow.com/community/developer-forum/1-ui-plocy-is-not-working/td-p/2987070
Please mark any helpful or correct solutions as such. That helps others find their solutions.
Mark