private void btnAceptar_Click(object sender, EventArgs e) { Clases.cFunciones fun = new Clases.cFunciones(); if (txt_Nombre.Text == "") { Mensaje("Debe ingresar una descripción para continuar"); return; } txt_PrecioVenta.Text = txt_PrecioVenta.Text.Replace(".", ""); if (txtCodigo.Text == "") { fun.GuardarNuevoGenerico(this, "Joya"); } else { fun.ModificarGenerico(this, "Joya", "CodJoya", txtCodigo.Text); } Mensaje("Datos grabados correctamente"); Botonera(1); fun.LimpiarGenerico(this); txtCodigo.Text = ""; Grupo.Enabled = false; }
private void btnAceptar_Click(object sender, EventArgs e) { if (txt_Nombre.Text == "") { Mensaje("Debe ingresar una descripción"); return; } if (cmb_CodProvincia.SelectedIndex < 0) { Mensaje("Debe ingresar una provincia"); return; } Clases.cFunciones fun = new Clases.cFunciones(); if (txtCodigo.Text == "") { fun.GuardarNuevoGenerico(this, "Ciudad"); } else { fun.ModificarGenerico(this, "Ciudad", "CodCiudad", txtCodigo.Text); } Mensaje("Datos grabados correctamente"); txtCodigo.Text = ""; txt_Nombre.Text = ""; Botonera(1); Grupo.Enabled = false; }
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; }
private void btnAceptar_Click(object sender, EventArgs e) { Clases.cFunciones fun = new Clases.cFunciones(); if (txt_Costo.Text != "") { txt_Costo.Text = txt_Costo.Text.Replace(",", "."); } if (txt_PrecioEfectivo.Text != "") { txt_PrecioEfectivo.Text = txt_PrecioEfectivo.Text.Replace(",", "."); } if (txt_PrecioTarjeta.Text != "") { txt_PrecioTarjeta.Text = txt_PrecioTarjeta.Text.Replace(",", "."); } if (txt_Nombre.Text == "") { Mensaje("Debe ingresar una descripción para continuar"); return; } if (txtCodigo.Text == "") { fun.GuardarNuevoGenerico(this, "Juguete"); } else { // if (txt_Ruta.Text != "") // txt_Ruta.Text = txt_Ruta.Text.Replace("\\", "\\\\"); fun.ModificarGenerico(this, "Juguete", "CodArticulo", txtCodigo.Text); } Mensaje("Datos grabados correctamente"); txtPorEfectivo.Text = ""; txtPorTarjeta.Text = ""; Botonera(1); fun.LimpiarGenerico(this); txtCodigo.Text = ""; Grupo.Enabled = false; }
private void btnAceptar_Click(object sender, EventArgs e) { if (txt_Nombre.Text == "") { Mensaje("Debe ingresar una descripción"); return; } Clases.cFunciones fun = new Clases.cFunciones(); if (txtCodigo.Text == "") { fun.GuardarNuevoGenerico(this, "TipoPrenda"); } else { fun.ModificarGenerico(this, "TipoPrenda", "CodTipoPrenda", txtCodigo.Text); } Mensaje("Datos grabados correctamente"); txtCodigo.Text = ""; txt_Nombre.Text = ""; }
private void btnAceptar_Click(object sender, EventArgs e) { Clases.cFunciones fun = new Clases.cFunciones(); if (txt_Nombre.Text == "") { Mensaje("Debe ingresar un color"); return; } if (txtCodigo.Text == "") { fun.GuardarNuevoGenerico(this, "Color"); } else { // if (txt_Ruta.Text != "") // txt_Ruta.Text = txt_Ruta.Text.Replace("\\", "\\\\"); fun.ModificarGenerico(this, "Color", "CodColor", txtCodigo.Text); } fun.LimpiarGenerico(this); Mensaje("Datos grabados correctamente"); }