private void btnBack_Click(object sender, EventArgs e) { StudentMenu sm = new StudentMenu(); this.Hide(); sm.Show(); }
private void btnLogin_Click(object sender, EventArgs e) { Student s1 = new Student(); s1.readdata(); for (int i = 0; i < s1.student_list.Count; i++) { if (txtID.Text == s1.student_list[i].ID && txtPass.Text == s1.student_list[i].pass) { s1.login2(txtID.Text); StudentMenu sm = new StudentMenu(); this.Hide(); sm.Show(); return; } } lblReenter.Text = "Wrong ID or Password !"; txtID.Clear(); txtPass.Clear(); }