Error in password recovery webpart

Hi,

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?
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).
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?
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.
Thank u so much for your help.
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?
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.
Oh okay.
I was thinking about the same.Thanks for the reply..
Hi,
I am going through your code
How is the password encryption happening?
Where are u calling password encryption method?
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).
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 ?
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.