Пример #1
0
        private void cursosToolStripMenuItem1_Click(object sender, EventArgs e)
        {
            Form frmC = Application.OpenForms.Cast <Form>().FirstOrDefault(x => x is ConsultCurso);

            if (Consult_7 == false || frmC == null)
            {
                if (frmC == null)
                {
                    consult_7 = new ConsultCurso();
                }

                consult_7.MdiParent = this;
                consult_7.Show();
                Application.DoEvents();
                Consult_7 = true;
            }
            else
            {
                consult_7.WindowState = System.Windows.Forms.FormWindowState.Normal;
            }
        }