Compartilhar via


GetGroupCollectionFromRole Method

The GetGroupCollectionFromRole method of the Users and Groups service returns information about the collection of cross-site groups assigned to the specified site group.

Parameters

roleName   A string that contains the name of the site group.

Return Value

An XML fragment in the following form that can be assigned to a System.Xml.XmlNode object:

<GetGroupCollectionFromRole xmlns="http://schemas.microsoft.com/sharepoint/soap/directory/">
   <Groups>
      <Group ID="3" Name="Group1" Description="Description" OwnerID="1" OwnerIsUser="False" />
      <Group ID="15" Name="Group2" Description="Description" OwnerID="12" OwnerIsUser="True" />
      <Group ID="16" Name="Group3" Description="Description" OwnerID="7" OwnerIsUser="False" />
   </Groups>
</GetGroupCollectionFromRole>

Example

The following code example displays information about the collection of cross-site groups assigned to a specified site group.

This example requires that a using (C#) or Imports (Visual Basic .NET) directive be included for the System.Xml namespace.

Requirements

Platforms: Microsoft Windows Server 2003

Web Reference: http://Server_Name/[sites/][Site_Name/]_vti_bin/UserGroup.asmx