private void button1_Click(object sender, EventArgs e) { if (cliente == null) { cliente = new frmListarCliente("turno"); cliente.Owner = this; cliente.FormClosed += new FormClosedEventHandler(ClienteFormClosed); cliente.ShowDialog(); } }
private void listarClientesToolStripMenuItem_Click(object sender, EventArgs e) { if (listarCliente == null) { listarCliente = new frmListarCliente(); listarCliente.MdiParent = this; listarCliente.FormClosed += new FormClosedEventHandler(lsitarcli_FormClosed); listarCliente.Show(); } }
private void ClienteFormClosed(object sender, EventArgs e) { cliente = null; }
void lsitarcli_FormClosed(object sender, EventArgs e) { listarCliente = null; }