Setting Lookup Values when Copying a Document

by dpoggi » Fri Oct 09, 2015 8:12 pm

I need to copy a document from one library to another and set some lookup fields based on workflow initiation parameters from the user. For instance, I'd like to get a Department Num as input and set that in the destination library so I can reference Department Name, Manager, etc. All the usual ways to update a field seem to fail for lookups with a message like...
The list item could not be inserted or updated because invalid lookup values were found for the following field(s) in the list: [Department Num].
Any help or examples would be great.
Thanks!
dpoggi
 
Posts: 2
Joined: Tue Sep 22, 2015 9:13 pm

by Roman Rylov » Tue Oct 13, 2015 10:32 am

Hello,

To update a lookup field you just need to write a integer value.
Please see example below:
UpdateLookupValueSample1.png
UpdateLookupValueSample1.png (5.34 KiB) Viewed 385 times

UpdateLookupValueSample2.png
UpdateLookupValueSample2.png (7.21 KiB) Viewed 385 times


In current example I update field with name "Contact".
User avatar
Roman Rylov
 
Posts: 325
Joined: Tue Nov 11, 2014 6:25 pm


Return to Workflow Actions Pack for Office 365