Export (0) Print
Expand All

WebSecurity.GetPasswordFailuresSinceLastSuccess Method

Returns the number of times that the password for the specified account was incorrectly entered since the last successful login or since the membership account was created.

Namespace:  WebMatrix.WebData
Assembly:  WebMatrix.WebData (in WebMatrix.WebData.dll)

public static function GetPasswordFailuresSinceLastSuccess(
	userName : String
) : int

Parameters

userName
Type: System.String
The user name of the account.

Return Value

Type: System.Int32
The count of failed password attempts for the specified account.

ExceptionCondition
InvalidOperationException

The SimpleMembershipProvider.Initialize(String, NameValueCollection) method was not called.

-or-

The InitializeDatabaseConnection() method was not called.

-or-

The SimpleMembershipProvider membership provider is not registered in the configuration of your site. For more information, contact your site's system administrator.

  • Medium trust for the immediate caller. This member can be used by partially trusted code.
Show:
© 2014 Microsoft