private void addNewCommandToolStripMenuItem_Click(object sender, EventArgs e) { if (newCommand == null) { newCommand = new NewCommand(clientController, user); newCommand.MdiParent = this; newCommand.FormClosed += new FormClosedEventHandler(newCommand_FormClosed); newCommand.Show(); } else { newCommand.Activate(); } }
void newCommand_FormClosed(object sender, FormClosedEventArgs e) { newCommand = null; //throw new NotImplementedException(); }