private void Txt_precioCom_KeyPress(object sender, KeyPressEventArgs e) { decimal pre = 0; var res = decimal.TryParse(txt_precioCom.Text, out pre); if (res) { helpValidacion helpValidacion = new helpValidacion(); helpValidacion.ValidarDecimal(e); } else { txt_precioCom.Text = ""; } }
private void Txt_precioVta_KeyPress(object sender, KeyPressEventArgs e) { helpValidacion helpValidacion = new helpValidacion(); helpValidacion.ValidarDecimal(e); }