Quantcast
Viewing all articles
Browse latest Browse all 10096

Lookup field value is not getting set when using Client object model

Hi All,

I am very new to SharePoint. 

I have a document library (contact). Have created a custom list (workstatus). Have added column to contact library which is lookup of workstatus.

Below is my code using which i am setting the lookup column value. Unfortunately code runs fine (no exceptions) but when i check in SharePoint value is not set for the given column.

FieldLookupValue lvworkstatus = new FieldLookupValue();
lvworkstatus.LookupId = workstatus;
item["crmworkstatus"] = lvworkstatus;
 item.Update();
context.Load(uploadFile);
context.ExecuteQuery();

kindly let know what is wrong / missing.

Thanks in advance

 

Viewing all articles
Browse latest Browse all 10096

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>