private void SendEmailWithPassword(string email, UserDS.UserDSRow user)
        {
            var values = new Dictionary <string, string>();

            values.Add("FullName", user["username"].ToString());
            values.Add("Password", user["password"].ToString());

            MailSender.SendEmail(email, UcentrikConfiguration.RestorePasswordSubject,
                                 MailSender.EmailTemplate.RestorePassword, values);
        }
        private void RestorePasswordByEmail()
        {
            var email = tbEmail.Text;

            UserDS.UserDSRow user = GetUser(email);
            if (user == null)
            {
                this.plhAccountDoesNotExist.Show();
            }
            else
            {
                this.SendEmailWithPassword(email, user);
                this.ShowRestoredState();
            }
        }