AnsweredAssumed Answered

How can I confirm all form validation before performing an action within Custom Javascript in Nintex Forms 2013 On-Prem?

Question asked by sdcmobile@charter.net on Feb 5, 2016
Latest reply on Jul 13, 2017 by bcobra

I have a custom Submit button function (listed below) that I only want to fire if all form validation passes successfully (required values, etc).

 

function DoSubmitButton(){

// Submit the form, display confirmation, and navigate back to the original page

NWF$(".nf-disableonsubmit[value=MySubmitButton]").click();

alert("Thank you. Your entry was successfully submitted.");

history.go(-1);

  }

 

Desired Change =

 

function DoSubmitButton(){

// Submit the form, display confirmation, and navigate back to the original page if all Form validation passes

if ("All form validation is true") {

NWF$(".nf-disableonsubmit[value=MySubmitButton]").click();

alert("Thank you. Your entry was successfully submitted.");

history.go(-1);

  }

}

 

Thanks!

Outcomes