ListItemCollection.GetById Method (Int32)
Returns the list item with the specified list item identifier.
Namespace: Microsoft.SharePoint.Client
Assemblies: Microsoft.SharePoint.Client.Silverlight (in Microsoft.SharePoint.Client.Silverlight.dll); Microsoft.SharePoint.Client (in Microsoft.SharePoint.Client.dll)
Syntax
'Declaration
<RemoteAttribute> _
Public Function GetById ( _
id As Integer _
) As ListItem
'Usage
Dim instance As ListItemCollection
Dim id As Integer
Dim returnValue As ListItem
returnValue = instance.GetById(id)
[RemoteAttribute]
public ListItem GetById(
int id
)
Parameters
id
Type: System.Int32The list item identifier.
Return Value
Type: Microsoft.SharePoint.Client.ListItem
Returns a ListItem instance representing the list item with the specified list item identifier.
Exceptions
Exception | Condition |
---|---|
[System.ArgumentException] | List item does not exist. Error code: -2147024809. |