UserProfileService.RemoveMembership method

Removes a membership for the specified account name.

Namespace:  WebSvcUserProfileService
Assembly:  UserProfileServices (in UserProfileServices.dll)

[SoapDocumentMethodAttribute("http://microsoft.com/webservices/SharePointPortalServer/UserProfileService/RemoveMembership", RequestNamespace = "http://microsoft.com/webservices/SharePointPortalServer/UserProfileService", 
	ResponseNamespace = "http://microsoft.com/webservices/SharePointPortalServer/UserProfileService", 
	Use = SoapBindingUse.Literal, ParameterStyle = SoapParameterStyle.Wrapped)]
public void RemoveMembership(
	string accountName,
	Guid sourceInternal,
	string sourceReference
)

Parameters

accountName
Type: System.String

The account name of the user.

sourceInternal
Type: System.Guid

The GUID for the member group for which the membership is removed.

sourceReference
Type: System.String

The unique reference for the member group of the membership to be removed.

ExceptionCondition
SoapException

The membership cannot be removed.

This method deletes the membership from the member group specified by the sourceInternal and sourceReference parameters for the specified user.

Show: