SPList.GetItemByUniqueId Method

Gets the list item by GUID.

Namespace:  Microsoft.SharePoint
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: Yes
Available in SharePoint Online

public SPListItem GetItemByUniqueId(
	Guid uniqueId
)

Parameters

uniqueId
Type: System.Guid

The GUID of the list item.

Return Value

Type: Microsoft.SharePoint.SPListItem
The list item.

ExceptionCondition
ArgumentException

The list item does not exist.

-or-

The list is not a user information list.

Show: