private void proceed_btn_Click(object sender, EventArgs e) { Home_Member hm = new Home_Member(); hm.getMemberStatus("Other"); hm.Show(); this.Hide(); }
private void logIn_Click(object sender, EventArgs e) { try { Account_BO account_BO = new Account_BO(); if (loginUserName_txt.Text == "" || loginPassword_txt.Text == "") { MessageBox.Show("Wrong!!! Enter the information fully"); } else { Member member = account_BO.getAdminOrMember(loginUserName_txt.Text); if (member.password == loginPassword_txt.Text) { if (member.type == "Admin") { Home_Admin ha = new Home_Admin(); ha.Show(); this.Hide(); } else { Home_Member hm = new Home_Member(); hm.getMemberStatus("Member"); hm.Show(); this.Hide(); } } else { MessageBox.Show("Incorect UserName or Password"); loginUserName_txt.Clear(); loginPassword_txt.Clear(); } } } catch { MessageBox.Show("Incorect UserName or Password"); } }