sharepoint - Retrieve content type columns values in C# -



sharepoint - Retrieve content type columns values in C# -

i have document library content type multiple columns in sharepoint2010. retrieve values in column using next code fails.

objcurrentweb = spcontext.current.web; objlist = objcurrentweb.lists["mynewlists"]; foreach (splistitem objlistitem in objlist.items) { id = (objlistitem["applicationid"]).tostring(); }

how retrieve values in content type columns correctly?

thank you!

it can fail in 2 cases: 1) there no such field "applicationid". ensure utilize field internal name 2) (objlistitem["applicationid"]) null, fails nullreferenceexception on casting string.

c# sharepoint sharepoint-2010 content-type document-library

Comments

Popular posts from this blog

maven fortify plugin : Unable to load build session with ID XXXXX .. See log file for more details -

c# - Primavera WebServices does not return any data -

android - Display emoji panel with genymotion - keyboard/touch input? -