This project has moved. For the latest updates, please go here.

Error in password recovery webpart

Jul 23, 2013 at 5:50 AM

When I am deploying password recovery webpart to a page and give a username and click on submit it is throwing me error, Control 'UserName' referenced by the ControlToValidate property of 'RequiredFieldValidator1' cannot be validated.
How can i resolve this?
Jul 23, 2013 at 5:52 AM
I'm guessing this is a publishing site? With publishing sites, they validate the web parts controls before saving. So to save the page, you'll have to actually put some text in the username field (it doesn't have to be valid text - just some characters).
Jul 23, 2013 at 6:04 AM
Thanks for the reply,
Issue got resolved.It was a code issue from my webpart.
I have one more doubt.
How you are sending mails through xslt?
From resource files are u sending emails?
Jul 23, 2013 at 1:36 PM
The default xslt templates are in the resource files. They can be edited from the FBA Site Configuration page. The edited entries are stored in SharePoint site properties.
Jul 23, 2013 at 2:11 PM
Edited Jul 23, 2013 at 2:19 PM
Thank u so much for your help.
Jul 24, 2013 at 6:00 AM
For my requirement,I need to make password recovery as a single page instead of giving user name and submit,then it goes to another page,give security answer as in your webpart.
I need user name,security question and answer in a single page and when i click on submit mail should be sent
How can i achieve this using your password recovery web part?
Jul 24, 2013 at 3:53 PM
Out of the box, there's no easy way to change that process if you've got questions and answers enabled.

I would suggest that you actually disable the Question and Answer feature in your membership provider. I don't think it's been designed very well by Microsoft. If the user forgets the answer to the question, there's no way to reset the password without doing it directly in the DB. You can disable it in the membership provider entry in your web.configs/machine.config.

If Question and Answer is disabled, it will just ask the user for their username or email address and send them a reset password.
Jul 25, 2013 at 9:33 AM
Oh okay.
I was thinking about the same.Thanks for the reply..
Jul 26, 2013 at 10:45 AM
I am going through your code
How is the password encryption happening?
Where are u calling password encryption method?
Jul 26, 2013 at 11:28 AM
It doesn't happen in my code - the membership provider takes care of it. It will "encrypt" it as specified in the web config: Clear (Unencrypted), Encrypted and Hashed (recommended, as it can't be decrypted, and doesn't require the same encryption keys on all servers).
Jul 26, 2013 at 11:47 AM
Edited Jul 26, 2013 at 11:50 AM
While I used password recovery webpart, password format ="hashed" it throwed error.Only password=clear is working.How can i make it work with password hashed ?
Jul 26, 2013 at 11:57 AM
You need the same encryption keys on all SharePoint servers. I suggest you use Hashed, which is more secure than encrypted and doesn't require the encryption keys.