When trying to grab a field by guid, do you need to surround the guid with {}? E.g.




  • Which SharePoint API you are referring to? Commented Feb 28, 2012 at 23:57
  • I am using SharePoint 2010 Commented Feb 29, 2012 at 0:02

1 Answer 1


SPListItem has 3 "Item" methods defined that take an identifier between brackets:

  • item[string fieldName]
  • item[int index]
  • item[Guid fieldId]

You seem to be trying to use item[Guid fieldId], but you are providing a string, not a Guid structure, so in effect you are calling item[string fieldName] and thus SharePoint expects a field name, not a field id.

You should be calling your method like so:

item[new Guid("{936DA01F-9ABD-4d9d-80C7-02AF85C822A8}"]

to properly form a Guid structure. With or without curly braces { } or parenthesis ( ), as the Guid constructor accepts both. Do NOT use square brackets [ ].

  • Thats what I was lookking for, but do I need to use item[new Guid("{xxx343-xx-324-xxx}"]? Commented Feb 29, 2012 at 0:34
  • Yes, with the new sorry. Edited my post. You can include curly braces or not, both will work.
    – Louis
    Commented Feb 29, 2012 at 2:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.