Skip to main content
Nintex Community Menu Bar

Reset Multi-Value list lookup control using JavaScript

  • Aug 26, 2016 7:14 PM UTC
  • 3 replies
  • 88 views
  • Translate All

Forum|alt.badge.img+3

Hello Everyone

I am currently working on Nintex Form where I want to reset Multi select list lookup control. On the form I have a Reset button. When user clicks Reset button I have to reset all controls on the form. I can reset all the controls using JavaScript but not sure how do I go about resetting multi-select List Lookup. I came across an example where using JavaScript we can set the default value for the multi-select list lookup but in my case I would need to do the reverse of that. https://community.nintex.com/thread/10276

Thank you in advance for your help.

3 replies

Forum|alt.badge.img+14
  • Scholar
  • Sep 4, 2016 6:43 PM UTC

I haven't tested it but I would say first line of code on the link provided actually clears all the selected options

NWF$(".multiChoice option:selected").removeAttr("selected");

Translate

Forum|alt.badge.img
  • Nov 11, 2016 6:05 AM UTC

Hello,

You can achieve this by following step:-

1. Add multiChoice class to the multi select control from setting.

2. Call following script from button to remove all selected items.

NWF$(".multiChoice option").each(function() {
$(this).prop("selected", true);
})
NWF$(".multiChoice button:nth-child(2)").click();

I hope this will help you.

Thanks & Regards,

-Samit

Translate

Forum|alt.badge.img+2
  • Aug 30, 2018 9:02 AM UTC

None of the above options worked for me to reset the multi lookup column in Nintex form 2013.

Is there any other way to achieve it.

Please help.

Translate