Ejemplo n.º 1
0
 private void cmdAceptar_Click(object sender, EventArgs e)
 {
     if (Validar())
     {
         LlenarProveedor();
         if (_Opcion == 1)
         {
             if (Prov.AgregarProveedores() >= 1)
             {
                 MessageBoxAdv.Show("Registro agregado", "Confirmacion", MessageBoxButtons.OK,
                                    MessageBoxIcon.Information);
             }
         }
         else if (_Opcion == 2)
         {
             if (Prov.ActualizaProveedores() >= 1)
             {
                 MessageBoxAdv.Show("Registro Actualizado", "Confirmacion", MessageBoxButtons.OK,
                                    MessageBoxIcon.Information);
             }
         }
         this.Close();
     }
 }