private void KeyEnterLogin() { User u = new User(); //u.isAdmin(); //u.isAdministrator(); u.getCashierIDfromDB(); try { if (u.isAuth(txtBoxCashierUser.Text, txtBoxPass.Text)) { this.Hide(); frmMain fm = new frmMain(); fm.Show(); } else { result = MessageBox.Show("Username and Password Incorrect or Not Completed", "Login Error", btn, MessageBoxIcon.Error); } //clearText(); } catch (Exception) { result = MessageBox.Show(loginpop, caption, btn, icon); } }
private void KeyEnterLogin() { User u = new User(); //u.isAdmin(); //u.isAdministrator(); u.getCashierIDfromDB(); try { if (u.isAuth(txtBoxCashierUser.Text, txtBoxPass.Text)) { this.Hide(); frmMain fm = new frmMain(); fm.Show(); } else result = MessageBox.Show("Username and Password Incorrect or Not Completed", "Login Error", btn, MessageBoxIcon.Error); //clearText(); } catch (Exception) { result = MessageBox.Show(loginpop, caption, btn, icon); } }
private void frmMain_Load(object sender, EventArgs e) { u.getCashierIDfromDB(); }