System.Web.Security.MembershipProvider.DeleteUser Method

Removes a user from the membership data source.

Syntax

public abstract bool DeleteUser (string name, bool deleteAllRelatedData)

Parameters

name
Documentation for this section has not yet been entered.
deleteAllRelatedData
true to delete data related to the user from the database; false to leave data related to the user in the database.

Returns

true if the user was successfully deleted; otherwise, false.

Remarks

Takes, as input, the name of a user and deletes that user's information from the data source. If deleteAllRelatedData is true, then all user data stored in the database for the System.Web.Security.Roles, System.Web.HttpContext.Profile, and System.Web.UI.WebControls.WebParts.WebPart personalization is also deleted.

Requirements

Namespace: System.Web.Security
Assembly: System.Web (in System.Web.dll)
Assembly Versions: 2.0.0.0
Since: .NET 2.0