cancel
Showing results for 
Search instead for 
Did you mean: 
Workflow Hero

Checkboxes - Select All

Jump to solution

I have a list lookup which displays the multiple values retrieved as a checkbox list.

I also have a yes/no box above called SelectAll.

Is there any way to set it so that when SelectAll is ticked, all the values in the checkbox list are ticked?

Any help would be appreciated. Thanks.

0 Kudos
Reply
3 Replies
Workflow Hero

Re: Checkboxes - Select All

Jump to solution

Only with JavaScript. You would need to build something like this into your form:

$("#checkAll").click(function(){    
$
('input:checkbox').not(this).prop('checked', this.checked);
});
Reply
Workflow Hero

Re: Checkboxes - Select All

Jump to solution

I'm not very experienced with javascript or using it in Nintex Forms.

Could you please explain how to set this up?

I've put the javascript you posted into the custom javascript section of the settings, but I'm not too sure where to go from there.

I've replaced the checkAll ID and "input:checkbox" with the ClientID javascript variable name for each control.

NWF$(selectallCID).click(function(){    
NWF$(countriesCID).not(this).prop('checked', this.checked);
});

Am I doing this right?

0 Kudos
Reply
Workflow Hero

Re: Checkboxes - Select All

Jump to solution

The second selector of "input:checkbox" is needed so it finds all the available check boxes and then checks them. If you add one control, then it may not select them all

0 Kudos
Reply