MembershipProvider.OnValidatingPassword(ValidatePasswordEventArgs) Method

Definition

Raises the ValidatingPassword event if an event handler has been defined.

C#
protected virtual void OnValidatingPassword(System.Web.Security.ValidatePasswordEventArgs e);

Parameters

Examples

For an example of a MembershipProvider implementation, see Implementing a Profile Provider.

Remarks

The OnValidatingPassword virtual method is used during the CreateUser, ChangePassword, and ResetPassword methods to raise the ValidatingPassword event if a MembershipValidatePasswordEventHandler has been specified. The e parameter is used to pass a ValidatePasswordEventArgs object to the MembershipValidatePasswordEventHandler event handler. When the ValidatingPassword event has completed, the properties of the ValidatePasswordEventArgs object supplied as the e parameter can be examined to determine whether the current action should be canceled and if a particular Exception, stored in the FailureInformation property, should be thrown.

Applies to

Product Versions
.NET Framework 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1

See also