private void frmMain_FormClosed(object sender, FormClosedEventArgs e) { frmMain frml = new frmMain(); frml.Close(); this.Hide(); frmLogin frm = new frmLogin(); frm.Closed += (sender1, args) => this.Close(); frm.Show(); }
private void logoutToolStripMenuItem_Click(object sender, EventArgs e) { frmMain frml = new frmMain(); frml.Close(); this.Hide(); frmLogin frm = new frmLogin(); frm.Closed += (sender1, args) => this.Close(); frm.Show(); }