This project has moved and is read-only. For the latest updates, please go here.

Multiple Multi Select Box issue

Dec 12, 2012 at 1:45 PM
Edited Dec 12, 2012 at 9:38 PM


I am having an issue implementing your code and I tried to search the documentation and discussions to no avail. I may certainly have missed the thread, but I'm desperate now as my rollout date draws closer. I had originally abandoned this code and attempted a infopath solution but soon found myself back. 

**Edit** I found a post which looks to describe my situation the closest but see no resolution on that:

I am attempting to get three multi selectable boxes to work, there is a category box, a product box and a family box. what is strange is when I have the category box be multi select and leave product as a drop down box, I can select multiple category items and when I click the product drop down, all the values for each check box I selected in the multi value box for category show combined in the product drop down. However, when I change the product box from a drop down to a multi value box, all the values from the list are immediately pulled into the product multi value box with no filtering. 

My goal is to have three multi selectable value boxes which cascade based on the previous multi select boxes value, showing combined related values for each checkbox selected in the previous box. Category pulls from the category list, product pulls from CategoryRelationList and SubFamily from CategoryRelationListL3.

Again, I didn't see this specifically in the discussions when I checked. I apologize if this was mentioned already. You have done great work here and I appreciate all the time you have saved me.

<script language="javascript" src="/AppSupport/jquery-1.8.2.min.js" type="text/javascript"></script><script language="javascript" src="/AppSupport/jquery.SPServices-0.7.2.min.js" type="text/javascript"></script><script language="javascript" type="text/javascript">

$(document).ready(function() {
listName: "AppSupportProdTest",
relationshipList: "CategoryRelationList",
relationshipListParentColumn: "Category",
relationshipListChildColumn: "Title",
parentColumn: "Category",
childColumn: "Product",
debug: true
listName: "AppSupportProdTest",
relationshipList: "CategoryRelationListL3",
relationshipListParentColumn: "SubFamily1",
relationshipListChildColumn: "Title",
parentColumn: "Product",
childColumn: "SubFamily",
debug: true

Dec 13, 2012 at 2:27 PM

Are you seeing any script errors?


Dec 13, 2012 at 3:24 PM

no, none at all. which is why I am so confused. it all works ok when the first box is a multi select box, the second box is a drop down and the third one is a multi select box, but not when all three are multi select boxes as I require.

In the scenario above, when I select multiple categories in the first multi select box, the next drop down gets dynamically populated with all the subcategories related to all the categories I multi selected in the first box. And when I select a single selection from that second drop down (this is all I can do with the drop down anyway) the third multi select box get populated with third level sub-sub categories related to the single selection from the second drop down.

So when I change the second drop down to a multi select so all three are multi select boxes, thats when the second and third boxes break and all the values from the lists that feed the second box populate the second multi select box immediately and the same with the third multi select box from the third list. I am looking the multi select box to be blank at first and start to dynamically populate with additional data the more items from the previous multi selectable box are selected.

Its almost as if it only works one level down as long as the previous box is always a drop down box vs a multi select box feeding another multi select box.

I hope I am making sense, I'm new to this, and I haven't seen this used in the way I am trying to get it to work.

Thanks again

Dec 17, 2012 at 11:57 AM

Can I assume that you are making these "multi-select" in the list settings? Are these then 3 sets of checkboxes or still dropdowns? I gather you mean dropdowns but want to be sure I know how you are making them multi-select. This should work so the more info the better.

Dec 17, 2012 at 4:01 PM

These three columns are set up in the list "AppSupportProdTest" as column types "lookup" and "<label for="ctl00_PlaceHolderMain_OptionalSettings_ctl00_ctl01_cbxAllowMultiValue">Allow multiple values" checked under the list column settings for those three columns. In the SPServices Code, listName: "AppSupportProdTest". For clarity purposes, I will call each column 1, 2 and 3. The selection process starts with 1 which feeds 2 which feeds 3. </label>

<label for="ctl00_PlaceHolderMain_OptionalSettings_ctl00_ctl01_cbxAllowMultiValue">Its only when I uncheck "Allow multiple values" on column 2 that everything works other that being able to multi select fields from column 2. So multiple values can be selected in the form of "AppSupportProdTest" for column 1 (<label for="ctl00_PlaceHolderMain_OptionalSettings_ctl00_ctl01_cbxAllowMultiValue">Allow multiple values checked) </label>which dynamically populates the lookup field (without multiple values checked in list column settings) which then dynamically populates fields in lookup field 3 ("allow multiple values checked"). </label>

<label for="ctl00_PlaceHolderMain_OptionalSettings_ctl00_ctl01_cbxAllowMultiValue">Its when I enable "allow multiple values" in column 2 that it all breaks. All values are shown in column 2 and 3 with no lookup happening.</label>

<label for="ctl00_PlaceHolderMain_OptionalSettings_ctl00_ctl01_cbxAllowMultiValue"></label>I hope that makes more sense. If I can provide screenshots or anything of any more help I will do that. I really appreciate the help. I am pulling my hair out here trying to figure out why this is not working. It seems really straight forward.



Dec 17, 2012 at 4:12 PM

Additionally, on the list form the multi select box is just two square boxes that populate with the data dynamically from the previous option box above (previous column) a scroll bar dynamically appears in the option box on the left with data listed vertically.

I can then "add" data from the left column box to the right column box to "choose my selections". Its is then that I would expect the next lookup columns option boxes in the next row on the form to populate dynamically with the multiple options I "added" from the previous columns.

When column 1 is set up in this fashion, it will dynamically populate column2's option box only when I uncheck to allow multiple values on column 2 which converts the box to a true single select drop down box (click arrow to drop down and show options but can only select 1) . Then anytime I select (add) multiple items from column1 will the single drop down dynamically grow and shrink based on how many items I selected (added) in column1. When this is set, I can then use the single selection from column to to populate items in column3's multi select boxes (again a populated box on the left which I can multi select option and click "add" multiple selections to the box on the right.

When I enable the allow multi selection on columm2 is when it breaks again. The lookup pulls in all list data from the datasource for that lookup column and it is not dynamically populated using the previous columns selection/s.

Hope that helps.

Dec 17, 2012 at 5:09 PM
Column 1, 2 and 3 on the form. With column 2 set to not allow multiple selections from the lookup field. It works this way,

whatever is "added/selected" from column 1 will populate the small dropdown in column 2 dynamically and what is selected in column 2

Only can select 1 option since "allow multiple select is unchecked" will populate column 3 on the bottom of the form.
When column 2 (middle option box in the form) is changed to "allow multiple selections" like the others is when 

things break and you see every item in column2's lookup. Column 3 no longer relates to column 2 as well as you can see
it too is displaying all the data from that lookup column.

This is column 2. I would click "allow multiple values" as already set on 1 and 3 is when it breaks. 


Dec 18, 2012 at 10:53 AM

I see what you are trying to do. I have not really tried this, but it should work. I do notice that some of the items are duplicated in the 3rd multiselect option. I am wondering if there is a data issue that might be causing this. The only way to really test that would be to try on different lists that has a smaller dataset and no items with the same title. That can be a big task, but everything else seems to be okay.

Dec 18, 2012 at 3:56 PM

I removed most of the data from all the lists and made sure there was no duplication in the title column in the list and still nothing unfortunately. At this point I can't even make a multi select box (with add button in SP) feed another box. I removed the third cascading box out of the code so there was only the first and second both as multi select options and nothing, the second box always has all data in it. I would expect it to be blank until some multi select options were populated (added) in the first box.

Again, as soon as the second box gets changed to a single drop down (no multi) in the sharepoint column properties, it then will dynamically populate from the selections in the first multi select column.

I have pulled in the lists and their data into an excel sheet if anyone cares to take a looks to see why this isn't working.

Has anyone successfully done this? Have all data dynamically populate multi selectable fields in the sharepoint form as I show above? It is almost as if there needs to be a normal lookup dropdown with no multiple selections allowed somewhere in this mix to make it all work.


Dec 28, 2012 at 11:33 PM

Sorry to get back to this so late, but something is definitely going on here. I have seen the SPServices code and it looks like it should work. However, as this is Marc's code I am not going to claim I know it as well as he does. The main issue here I think is that this type of lookup draws a very complex set of boxes on the screen and it needs to control/filter each subsequent box. Have you validated the different developer tools to be sure there is no javascript errors, and also maybe check the response object for the second one to see if it has an error.

Jan 9, 2013 at 9:26 PM

Thanks for all the help trying to get this to work...I didn't end up getting this to work no matter how I tried to set it up. I even tried a basic set up. As long as I used multi select boxes as the initial selection, it would never work. I suspect not many of the users have tried it this way as it is a bit uncommon to have a many to many multi select dropdown vs a one to many from a single dropdown as the starting point, so I am chalking this up as not possible currently.

Just letting everyone know in case someone tries this in their environment without beating their heads in wondering if its possible as I did. I ended up purchasing a 3rd party SP add on for a couple hundred bucks that does this out of the box. Setup took a couple minutes and it did what I wanted. I ran out of time on my deployment so this worked out perfectly.

Thanks again for the help, I wish it would have worked as this all the SPServices are great tools!