Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

How to highlight the field label upon UI Action

shun6
Giga Sage
Giga Sage

Hi all,

I have a requirement to highlight field label when user click the UI Action.

For example if field "A" is empty and user click the UI action, field "A" would be highlighted.

I don't want to make field "A" mandatory field.

 

Thanks.

2 REPLIES 2

Anurag Tripathi
Mega Patron
Mega Patron

Hi,

Using a code like below you can make a field flash

 

g_form.flash("incident.number","#FFFACD",0);

 

 

-Anurag

Sandeep Rajput
Tera Patron
Tera Patron

@shun6 You can use the flash method in the client side code of a UI Action to highlight a specific field.

g_form.flash("incident.number", "#FFFACD", 0);
 
Hope this helps.