Condividi tramite


GroupCollection.GetById method

Returns a group from the collection based on the member ID of the group.

Namespace:  Microsoft.SharePoint.Client
Assembly:  Microsoft.SharePoint.Client (in Microsoft.SharePoint.Client.dll)

Syntax

'Declaration
Public Function GetById ( _
    id As Integer _
) As Group
'Usage
Dim instance As GroupCollection
Dim id As Integer
Dim returnValue As Group

returnValue = instance.GetById(id)
public Group GetById(
    int id
)

Parameters

  • id
    Type: System.Int32

    A 32-bit integer that specifies the member ID.

Return value

Type: Microsoft.SharePoint.Client.Group
A Group object that represents the group.

Exceptions

Exception Condition
SPException

The group cannot be found. Error Code: -2130575246.

ArgumentException

An unknown or incorrect group collection type is to be initialized. Error Code: -2147024809.

UnauthorizedAccessException

The current user has insufficient permissions. Error Code: -2147024891.

See also

Reference

GroupCollection class

GroupCollection members

Microsoft.SharePoint.Client namespace