private void btnAddStudent_Click(object sender, EventArgs e) { //Set the pannel height panelLeft.Height = btnAddStudent.Height; panelLeft.Top = btnAddStudent.Top; //Go to add student form FormAddStudents frm = FormAddStudents.SetGUIPlacements(); this.Hide(); frm.Show(); }
public static FormAddStudents SetGUIPlacements() { if (instance == null || instance.IsDisposed) { instance = new FormAddStudents(); } else { instance.BringToFront(); } return(instance); }