private void btnAceptar_Click(object sender, EventArgs e) { Clases.cFunciones fun = new Clases.cFunciones(); if (fun.ValidarFecha(txtM_Fecha.Text) == false) { Mensaje("La fecha no es válida"); return; } if (txt_Nombre.Text == "") { Mensaje("Debe ingresar una descripción para continuar"); return; } if (txtCodigo.Text == "") { fun.GuardarNuevoGenerico(this, "Articulo"); } else { // if (txt_Ruta.Text != "") // txt_Ruta.Text = txt_Ruta.Text.Replace("\\", "\\\\"); fun.ModificarGenerico(this, "Articulo", "CodArticulo", txtCodigo.Text); } Mensaje("Datos grabados correctamente"); if (txt_Ruta.Text != "") { Imagen.Image.Save(txt_Ruta.Text); } if (txt_CodigoBarra.Text != "") { var result = MessageBox.Show("Desea Imprimir", "Información", MessageBoxButtons.YesNo, MessageBoxIcon.Question); if (result == DialogResult.Yes) { cCodigoBarra objCodBarra = new cCodigoBarra(); objCodBarra.Insertar(ImagenCodigo, 1, 2); FrmVerReporteBarra frm = new FrmVerReporteBarra(); frm.Show(); } } Botonera(1); fun.LimpiarGenerico(this); Imagen.Image = null; ImagenCodigo.Image = null; txtCodigo.Text = ""; Grupo.Enabled = false; }