Represents a field in a list on a SharePoint Foundation Web site.

learn more… | top users | synonyms

8
votes
4answers
46k views

How to set ListItem Lookup Field value

How do I set a ListItem's Lookup field using code? SPFile file = list.RootFolder.Files.Add(destUrl, iStream, true); SPListItem item = file.Item; item["DocumentID"] = DocID.ToString(); ...