OnChange Client script not displaying Alert

Nisha30
Kilo Sage

Hi Experts,

 

No Alert is displayed on the ONCHANGE client script for incident when the value is changed on Incident form

 

Nisha30_1-1726666335851.png

 

 

Nisha30_0-1726666431821.png

 

 

4 REPLIES 4

Anurag Tripathi
Mega Patron
Mega Patron

Hi,

You might have a error in your script that may be causing it. 

Remove all code and just leave 1 alert and see if you get it.

 

-Anurag

Badrinarayan
Tera Guru

Hi @Nisha30 , 

Please Call the Alert before the Script includes  

 I mean to say that 

 In Line Number 8 : alert('call to background');

In Line Number 9 : var ga =new GlideAjax('CBIUtilsAjax');

 

Test by changing the Field "Specific_issue " and try

 

It is Working Fine in my PDI 
Screenshot 2024-09-18 at 7.13.12 PM.png

Thanks Regards, 

Badrinarayan

Rajesh Chopade1
Mega Sage

Hi @Nisha30 

try following ways to troubleshoot your issue:

 

Make sure that the field you’re listening to in the onChange script is correct. The field name in the script must match the field on the form.

 

If there’s a condition on the onChange script, ensure that it evaluates to true when the field changes.

 

Sometimes, browser issues can affect JavaScript execution. Try testing in a different browser or in incognito mode.

 

Look at the browser’s console (F12) for any JavaScript errors that might be preventing the script from executing.

 

i hope my answer helps you to resolve your issue, if yes please mark my answer helpful and correct.

thank you

rajesh

d_17
Tera Expert

@Nisha30 

Check if you have another field called specific issue

if you still have issue, delete this and create new from scratch line by line