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.

Catalog client script for catalog item banner

Johnson13
Tera Expert

I need help to modify and add to this script for the banner to display in RED and bold on top of the catalog item form. 

 

function onLoad() {
    g_form.addInfoMessage('**Submission does not guarantee the request will be approved!**', 'danger');
}
1 ACCEPTED SOLUTION

Mohammed Al-Mar
Tera Guru

Hi @Johnson13 you can use html tags, like:

function onLoad() {
    g_form.addErrorMessage('<strong>Submission does not guarantee the request will be approved!</strong>');
}

View solution in original post

5 REPLIES 5

Mohammed Al-Mar
Tera Guru

Hi @Johnson13 you can use html tags, like:

function onLoad() {
    g_form.addErrorMessage('<strong>Submission does not guarantee the request will be approved!</strong>');
}

RAMANA MURTHY G
Mega Sage

Hello @Johnson13 ,

You can write like below

g_form.addInfoMessage('<font style="color:red"><b>**Submission does not guarantee the request will be approved!**</b></font>');

 

the output will be like the below

RAMANAMURTHYG_0-1728878878572.png

 

 

Please mark my answer helpful  & correct if it helps you
Thank you

G Ramana Murthy
ServiceNow Developer

Omkar Mone
Mega Sage

 

Hello,

 

If you want to show it with Info message, you can do something like this - 

 

function onLoad() {
    var message = '<strong style="color:red;">Submission does not guarantee the request will be approved!</strong>';
	g_form.addInfoMessage(message);
}

Eshwar Reddy
Kilo Sage

Hi @Johnson13 

Use below script

g_form.addInfoMessage('<font style="color:red"><b>Note: Submission does not guarantee approval of your request. Please ensure all necessary information is provided.</b></font>');


Thanks
Eshwar