private void updateADepartmentInformationToolStripMenuItem_Click(object sender, EventArgs e) { if (udi == null) { udi = new UpdateDepartmentInfo(); udi.MdiParent = this; udi.FormClosed += udi_FormClosed; udi.Show(); } else { udi.Activate(); } }
void udi_FormClosed(object sender, FormClosedEventArgs e) { udi = null; }