cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Nintex Form validations not triggering when using Client Click

Hello,

 

I'm using a SP list form as a modal window in another parent SP list. The modal window has a repeating section and I have added validation rules on the user input fields inside the repeating section. I also want to pass a value from the modal window back to the calling parent list form. To do that, I use the method "SP.UI.ModalDialog.CommonModalDialogClose" with parameters to return the value to the calling parent list form. This all works fine, except that when I use the Client Click event, the native Nintex form validation functions aren't called. It seems that when using Client Click, the Nintex form validations are overridden by the method that I call in the Client Click. The form validations work fine when I remove the method from the Client Click.

 

Is there a way to call the Nintex form validations JS function in the Client Click of a button? If so, what is the exact name of the function to call?

 

Thank you!

Labels: (2)
Tags (1)
0 Kudos
Reply
5 Replies
Workflow Hero

Re: Nintex Form validations not triggering when using Client Click

Try calling

     ctrl.trigger("focusout");

or

     NWF.FormFiller.Functions.ProcessOnChange(ctrl);

for all controls in your repeating section.

Kind regards

Manfred

0 Kudos
Accept as Solution Reply
Not applicable

Re: Nintex Form validations not triggering when using Client Click

Thanks Manfred for responding to my question. I wanted to clarify what you meant by "ctrl" in your solution. Do you mean add a reference to the repeating section control, or the input control(s)? Also, I assumed that you meant to add this code to the Client Click event of the button. Let me know if that is not the right place for your suggested code. Thanks again!

0 Kudos
Accept as Solution Reply
Workflow Hero

Re: Nintex Form validations not triggering when using Client Click

You have to call the function for the input controls in client click event.

0 Kudos
Accept as Solution Reply
Not applicable

Re: Nintex Form validations not triggering when using Client Click

Thank you, but I do have more questions. How do I get a handle to the input control inside the repeating section. I tried storing the Client ID of the input control in a JavaScript variable, but that did not work. Here's what I tried in the Client Click event of the button. In the code below, vTravelDays is the JavaScript variable name of the input control inside the repeating section.

NWF.FormFiller.Functions.ProcessOnChange(NWF$("#" +vTravelDays)); SP.UI.CommonModalDialog(1, NWF$("#" + vTravelGrandTotal).val());

0 Kudos
Accept as Solution Reply
Workflow Hero

Re: Nintex Form validations not triggering when using Client Click

Client ID gives you only access to controls in first row. To get access to controls in repeating section you have to use class names for the controls. Search for nf-repeater and take a look atJavaScript events in Nintex Forms .

Kind regards

Manfred

0 Kudos
Accept as Solution Reply