Ejemplo n.º 1
0
 private void Cadastrar_paciente_click(object sender, EventArgs e)
 {
     if (Application.OpenForms.OfType <CadastroPaciente>().Count() <= 0)
     {
         CadastroPaciente form = new CadastroPaciente();
         form.Show();
     }
     else
     {
         MessageBox.Show("Formulário já está aberto!");
     }
 }
Ejemplo n.º 2
0
        private void btn_cadastrar_Click(object sender, EventArgs e)
        {
            CadastroPaciente cadastroPaciente = new CadastroPaciente();

            cadastroPaciente.Show();
        }