Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Returns information about the collection of users for the current Web site.
Namespace: [UserGroup Web service]
Web service reference: http://Site/_vti_bin/UserGroup.asmx
Syntax
'Declaration
<SoapDocumentMethodAttribute("https://schemas.microsoft.com/sharepoint/soap/directory/GetAllUserCollectionFromWeb", RequestNamespace := "https://schemas.microsoft.com/sharepoint/soap/directory/", _
ResponseNamespace := "https://schemas.microsoft.com/sharepoint/soap/directory/", _
Use := SoapBindingUse.Literal, ParameterStyle := SoapParameterStyle.Wrapped)> _
Public Function GetAllUserCollectionFromWeb As XmlNode
'Usage
Dim instance As UserGroup
Dim returnValue As XmlNode
returnValue = instance.GetAllUserCollectionFromWeb()
[SoapDocumentMethodAttribute("https://schemas.microsoft.com/sharepoint/soap/directory/GetAllUserCollectionFromWeb", RequestNamespace = "https://schemas.microsoft.com/sharepoint/soap/directory/",
ResponseNamespace = "https://schemas.microsoft.com/sharepoint/soap/directory/",
Use = SoapBindingUse.Literal, ParameterStyle = SoapParameterStyle.Wrapped)]
public XmlNode GetAllUserCollectionFromWeb()
Return Value
Type: System.Xml.XmlNode
An XML fragment in the following form that can be assigned to a System.Xml.XmlNode object.
<GetUserCollectionFromWeb xmlns=
"https://schemas.microsoft.com/sharepoint/soap/directory/">
<Users>
<User ID="9" Sid="S-1-5-21-2127521184-1604012920-
1887927527-207153" Name="User1_Display_Name"
LoginName="DOMAIN\User1_Alias" Email="User1_E-mail"
Notes="Notes" IsSiteAdmin="False" IsDomainGroup="False" />
<User ID="10" Sid="S-1-5-21-2127521184-1604012920-1887927527-
4270" Name="User2_Display_Name" LoginName="DOMAIN\User2_Alias"
Email="User2_E-mail" Notes="Notes" IsSiteAdmin="False"
IsDomainGroup="False" />
.
.
.
</Users>
</GetUserCollectionFromWeb>
Examples
The following code example displays information about the collection of users for the current Web site. This example requires that a using (Visual C#) or Imports (Visual Basic) directive be included for the System.Xml namespace.
Dim usrgrpService As New Web_Reference_Folder_Name.UserGroup()
usrgrpService.Credentials = System.Net.CredentialCache.DefaultCredentials
Dim ndUsers As XmlNode = usrgrpService.GetAllUserCollectionFromWeb()
MessageBox.Show(ndUsers.OuterXml)
Web_Reference_Folder_Name.UserGroup usrgrpService = new Web_Reference_Folder_Name.UserGroup();
usrgrpService.Credentials= System.Net.CredentialCache.DefaultCredentials;
XmlNode ndUsers = usrgrpService.GetAllUserCollectionFromWeb();
MessageBox.Show(ndUsers.OuterXml);