Wednesday, September 28, 2011

Remove security question answer fields from ASP.net 4 createUserWizard

This can easily be done using a setting in web.config file like this:

<membership defaultProvider="MyCustomProvider">
<providers>
<clear/>
<add name=" MyCustomProvider " type="System.Web.Security.SqlMembershipProvider"
connectionStringName="SQL" minRequiredPasswordLength="5"
requiresQuestionAndAnswer="false" />
</providers>
</membership>

If you are using the default membership provider of asp.net, then you can easily switch off the security
question and answer fields by adding the 'requiresQuestionAndAnswer' attribute in your web.config's
membership provider tag. I did not get this attribute in auto list but works correct after adding it works well.

1 comment :