Ejemplo n.º 1
0
 private void metroTile1_Click(object sender, EventArgs e)
 {
     if (Application.OpenForms.OfType <ContainerModules>().Count() > 0)
     {
         MetroMessageBox.Show(this, "Já há um modulo aberto , feche-o e tente novamente", "Erro", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
     }
     else
     {
         ContainerModules container = new ContainerModules();
         container.Show();
         container.AddControl(new ModulesControl.ucMorador(), "Morador");
     }
 }
Ejemplo n.º 2
0
 private void tleApartamento_Click(object sender, EventArgs e)
 {
     if (Application.OpenForms.OfType <ContainerModules>().Count() > 0)
     {
         MetroMessageBox.Show(this, "Já há um modulo aberto , feche-o e tente novamente", "Erro", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
     }
     else
     {
         ContainerModules container = new ContainerModules();
         container.Show();
         container.AddControl(new Apartamento.ucAptCadastro(), "Apartamento");
     }
 }