Alert message below a field

MStritt
Tera Guru

I am looking to add an alert message below a field on our Case form, when a particular value is entered on our Account form. When the Enable Case Auto Close box is FALSE on the Account (Account.Enable Case Auto Close/u_enable_case_auto_close), I would like to add a message below the Enable Auto Close checkbox on the Case (Enable Case Auto Close/u_enable_auto_close) form (similar to below, but with different text).

Account form:

find_real_file.png

Case form:

find_real_file.png

1 ACCEPTED SOLUTION

Hi MS,

Either you have to use GlideAjax to check the field value in Account table or you can use UI policy.

Put same condition which you have in Business rule and then in the script section use that method to show the message.

find_real_file.png

 

find_real_file.png

Please mark correct and helpful, If it's worth for you.

Thanks,

Vinay

View solution in original post

13 REPLIES 13

'g_form' is client side object so use it in your 'onlaod' or 'onchange' client script. Also correct your field name for 'enable auto close' .

g_form.showFieldMsg('field_name', 'message','info');

Hi MS,

Either you have to use GlideAjax to check the field value in Account table or you can use UI policy.

Put same condition which you have in Business rule and then in the script section use that method to show the message.

find_real_file.png

 

find_real_file.png

Please mark correct and helpful, If it's worth for you.

Thanks,

Vinay

Hi Vinay,

I created a UI Policy with the script, and it works! 

find_real_file.png

Is there anyway to change/configure how the message box looks? Different color? Thinner box? Or like it does here:

find_real_file.png

UI Policy:

find_real_file.png

find_real_file.png

Also, is there a way to include a hyperlink in the message/text? 

Himanshu Dubey
Giga Guru

Hi 

 

You have to use onLoad() client script to show an alert see below script:

if(g_form.getValue('enable_auto_close') == false)

{

g_form.showFieldMsg('field_name', 'message','info');

}

 

Please mark correct and Helpful if it helps

Thanks & Regards

Himanshu Dubey