Error style not working in UI Policy Action
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-16-2025 01:33 AM
Hey team,
I'm trying to create a UI Policy Action to display an error message but for some reason it is not displaying the message with the red background. However, when I use warning or info the backgrounds yellow and blue work.
Does anybody know how to fix this issue?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-16-2025 01:37 AM
Can you share screenshot of UI policy that is not working as expected ?
If this helped to answer your query, please mark it helpful & accept the solution.
Thanks,
Bhuvan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-16-2025 02:10 AM
You can use below knowledge article for troubleshooting
https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0547063
If this helped to answer your query, please mark it helpful & accept the solution.
Thanks,
Bhuvan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-16-2025 01:51 AM
hi @andrespinilla ,
Please try to use one of below methods:
g_form.addErrorMessage('Form Error Message Text');
//Field error message
g_form.showFieldMsg('impact','Priority is high!','error');
Also Check if there any Client Scripts which take priority Over UI Policy.
Thanks & Regards,
Hanu
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-16-2025 01:55 AM
UI Policy Actions don’t support red error banners → only Info (blue) and Warning (yellow).
For red background error messages, you must use Client Scripts with g_form.showFieldMsg() or g_form.addErrorMessage().
Thanks,
Shubhra Saxena
