Updating Lookup field with Multiple Values?

Jul 18, 2014 at 6:52 AM
Is there any way to update a Lookup Field with multiple items in it? For now, i've only been able to update the lookup field with just only one item.

For example if I did this : List.updateItem([{id:myid, mylookup:"1,2,3,4,5"}]);

It would only update the lookup with the first value of "1", and not the rest of the values. BTW, "mylookup" is already set to take multiple values in the list settings.

Jul 19, 2014 at 6:16 AM
Actually, i just figured it out. You have to put in not only the IDs but the Title also :

List.updateItem([{id:myid, mylookup:"1;#Value1;#2;#Value2;#3;#Value3;#4;#Value4"}]);

Glad this is working cause i was getting a little worried for a second there.