Change color of helptext

robertpetrovics
Tera Contributor

I want to change the color of the help text under the field from red to dark blue, but can't seem to find where the help text is located. Can you give me a hand?

Untitled.png

Untitled1.png

  

1 ACCEPTED SOLUTION

SunilKumar_P
Giga Sage

Hi @robertpetrovics, Is this the OOB field? It looks like the field message. ServiceNow has a method called '

showFieldMsg' using which we can set the error message (red) or information message (blue). You can look into the client scripts configured on this field.

 

 

g_form.showFieldMsg("cmdb_ci", "Select the Impacted Service", "info");

 

SunilKumar_P_0-1707388532384.png

 

 

g_form.showFieldMsg("cmdb_ci", "Select the Impacted Service", "error");

SunilKumar_P_1-1707388572724.png

 

 

Regards,
Sunil

 

View solution in original post

5 REPLIES 5

Dr Atul G- LNG
Tera Patron
Tera Patron

Hi @robertpetrovics 

 

My knowledge say OOTB it is not possible, As it is error, so red colour suits here.

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.

Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]

****************************************************************************************************************

Hi @Dr Atul G- LNG, it is not an error, the message appears regardless of the number you put inside.

 

Try to check in Data Policy

Client script

UI messages

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.

Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]

****************************************************************************************************************

Ivan Betev
Mega Sage
Mega Sage

Hey @robertpetrovics ,


I presume that it is displayed via g_form.showFieldMsg in Client Script.

IvanBetev_0-1707388388743.png

 

Try to look for a client script that is doing that and change the color by using "info" or "warn" as the last parameter (see screenshot). You won't be able to easily set it to dark blue without manipulating the DOM though.

 

Regards, Ivan