Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

SimpleMembershipProvider.RequiresQuestionAndAnswer Property

Gets a value that indicates whether the membership provider requires that the user answer a security question for password reset and retrieval.

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

abstract RequiresQuestionAndAnswer : bool 
override RequiresQuestionAndAnswer : bool

Property Value

Type: System.Boolean
true if a security-question answer is required; otherwise, false. The default is true.

This property indicates whether the answer to a security question must be supplied in order for users to retrieve a password using the GetPassword(String, String) method, or to reset their password using the ResetPassword(String, String) method.

If the SimpleMembershipProvider class has been initialized using a call to the InitializeDatabaseConnection() method, this property returns false. However, if the InitializeDatabaseConnection() method has not been called, and if you have configured your site to use the standard ASP.NET membership provider, this property is passed through to the standard membership provider. When you use the standard membership provider, the value is set in the application configuration file (Web.config). For more information, see the SimpleMembershipProvider class overview.

Show:
© 2015 Microsoft