예제 #1
0
        private void Btn_ChangePass_Click(object sender, EventArgs e)
        {
            Account account = this.Tag as Account;

            if (Txb_OldPass.Text == account.Password)
            {
                if (Txb_NewPass.Text == Txb_Confirm.Text)
                {
                    AccountDAO.Instance.ChangePassword(Txb_DisplayName.Text, Txb_NewPass.Text);
                    MessageBox.Show("Password Changed.", "Notification", MessageBoxButtons.OK);
                    Txb_OldPass.Clear();
                    Txb_NewPass.Clear();
                    Txb_Confirm.Clear();
                }
                MessageBox.Show("New Password must be confirm.", "Notification", MessageBoxButtons.OK);
            }
            MessageBox.Show("Wrong Password.", "Notification", MessageBoxButtons.OK);
        }
예제 #2
0
 private void Btn_Cancel_Click(object sender, EventArgs e)
 {
     Txb_OldPass.Clear();
     Txb_NewPass.Clear();
     Txb_Confirm.Clear();
 }