How to create an alert box with "YES" or "NO" Button in incident Form

Pragati4
Tera Contributor

How to create an alert box with "YES" or "NO" Button in incident Form

Need to create an alert box in incident form for some condition(ex: if caller company is XYZ then while submitting the form alert window should come )!!

1 ACCEPTED SOLUTION

HarshTimes
Tera Guru

Hi Pragati

YOu need a confirm box not alert. Create a on submit client script with your company condition and add the below script 

confirm("company is xyz...");

This will give you ok and cancel button. You can code it according to your requirement.

 

-Harsh

View solution in original post

5 REPLIES 5

Akash4
Kilo Sage
Kilo Sage

Hi Pragati,

 

You may use the following onSubmit client script:

function onSubmit() {
    //Type appropriate comment here, and begin script below
      var myCompany = g_form.getValue('u_company');
     confirm("Your company is" + myCompany ", do you want to continue?");

}

Thanks

Akash

Regards, Akash
If my response proves useful, please mark it "Accept as Solution" and "Helpful". This action benefits both the community and me.