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.
Removes the specified permission from the list.
Namespace: [Permissions Web service]
Web service reference: http://Site/_vti_bin/Permissions.asmx
Syntax
'Declaration
<SoapDocumentMethodAttribute("https://schemas.microsoft.com/sharepoint/soap/directory/RemovePermission", RequestNamespace := "https://schemas.microsoft.com/sharepoint/soap/directory/", _
ResponseNamespace := "https://schemas.microsoft.com/sharepoint/soap/directory/", _
Use := SoapBindingUse.Literal, ParameterStyle := SoapParameterStyle.Wrapped)> _
Public Sub RemovePermission ( _
objectName As String, _
objectType As String, _
permissionIdentifier As String, _
permissionType As String _
)
'Usage
Dim instance As Permissions
Dim objectName As String
Dim objectType As String
Dim permissionIdentifier As String
Dim permissionType As String
instance.RemovePermission(objectName, _
objectType, permissionIdentifier, _
permissionType)
[SoapDocumentMethodAttribute("https://schemas.microsoft.com/sharepoint/soap/directory/RemovePermission", RequestNamespace = "https://schemas.microsoft.com/sharepoint/soap/directory/",
ResponseNamespace = "https://schemas.microsoft.com/sharepoint/soap/directory/",
Use = SoapBindingUse.Literal, ParameterStyle = SoapParameterStyle.Wrapped)]
public void RemovePermission(
string objectName,
string objectType,
string permissionIdentifier,
string permissionType
)
Parameters
objectName
Type: System.StringA string that contains the name of the list.
objectType
Type: System.StringA string that specifies List.
permissionIdentifier
Type: System.StringA string that contains the name of the site group, the name of the cross-site group, or the user name (DOMAIN\User_Alias) of the user to whom the permission applies.
permissionType
Type: System.StringA string that specifies user, group (cross-site group), or role (site group).
Remarks
To access the Permissions service and its methods, set a Web reference to https://Server_Name/[sites/][Site_Name/]_vti_bin/Permissions.asmx.
Examples
The following code example removes the permission to a list for the specified user.
Dim permService As New Web_Reference_Folder_Name.Permissions()
permService.Credentials = System.Net.CredentialCache.DefaultCredentials
permService.RemovePermission("List_Name", "List", "Cross-site_Group", "group")
Web_Reference_Folder_Name.Permissions permService = new Web_Reference_Folder_Name.Permissions();
permService.Credentials= System.Net.CredentialCache.DefaultCredentials;
permService.RemovePermission("List_Name", "List", "Cross-site_Group", "group");