Skip to main content

Is it possible to redirect to the home page on click of "Cancel"/"Save" button? JavaScript is not working on button clicks

Hi please see these related threads:

https://community.nintex.com/message/39695

https://community.nintex.com/message/39719#comment-39719


Thanks Cassy,

I was able to achieve the functionality for the "Save" button by the form redirect url option. For "Cancel" buon I have added javascript


hi aditya,
how did you achieve via javascript to redirect page by clicking on Cancel button,
Could you share your code here


Yes,

  • Change  the "Button Type" to JavaScript in the button control setting
  • Then in the "Advanced" option of the button control I added  CancelRedirect() in "Client Click"
  • In the form settings custom javascript add

function CancelRedirect()

  {

  

   window.location.replace("<Pageurl>");

  }


Reply