System.Web.Security.ValidatePasswordEventArgs.Cancel Property

Gets or sets a value that indicates whether the current create-user, change-password, or reset-password action will be canceled.

Syntax

public bool Cancel { set; get; }

Value

Documentation for this section has not yet been entered.

Remarks

The ValidatePasswordEventArgs.Cancel property is used to cancel the current MembershipProvider.CreateUser(string, string, string, string, string, bool, object, MembershipCreateStatus@), MembershipProvider.ChangePassword(string, string, string), or MembershipProvider.ResetPassword(string, string) action. You can cancel the current action by setting the ValidatePasswordEventArgs.Cancel property to true during the MembershipProvider.ValidatingPassword event.

If you cancel the current action by setting the ValidatePasswordEventArgs.Cancel property to true, you can set the ValidatePasswordEventArgs.FailureInformation property to an exception that describes the reason for the password-validation failure. The calling method will throw the exception that the ValidatePasswordEventArgs.FailureInformation property is set to. If the ValidatePasswordEventArgs.FailureInformation property is null, the caller will throw a generic password-validation failure exception.

Requirements

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