private void BuscarmetroButton1_Click(object sender, EventArgs e) { if (ValidarBuscar() == false) { MessageBox.Show("No existe un producto con este ID"); return; } LlenaCampos(UbicacionesBLL.Buscar(Convert.ToInt32(IdnumericUpDown.Value))); }
public bool ValidarBuscar() { if (IdnumericUpDown.Value <= 0) { return(false); } if (UbicacionesBLL.Buscar(Convert.ToInt32(IdnumericUpDown.Value)) == null) { return(false); } return(true); }
private void BuscarButton_Click(object sender, EventArgs e) { int id; Ubicaciones ubicacion = new Ubicaciones(); int.TryParse(IdNumericUpDown.Text, out id); Limpiar(); ubicacion = UbicacionesBLL.Buscar(id); if (ubicacion != null) { MessageBox.Show("Ubicacion Encontrado"); LlenarCampo(ubicacion); } else { MessageBox.Show("Ubicacion no encontrado"); } }
public void Buscarbutton_Click(object sender, EventArgs e) { Ubicacion Ubicaciones = new Ubicacion(); int.TryParse(IDnumericUpDown.Text, out int id); Limpiar(); Ubicaciones = UbicacionesBLL.Buscar(id); if (Ubicaciones != null) { MessageBox.Show("Producto Encontrado."); LlenaCampo(Ubicaciones); } else { MessageBox.Show("Producto no encontrado."); } }
private void BuscarButton_Click(object sender, EventArgs e) { int id; Ubicaciones ubicaciones = new Ubicaciones(); int.TryParse(UbicacionIdNumericupDown.Value.ToString(), out id); limpiar(); ubicaciones = UbicacionesBLL.Buscar(id); if (ubicaciones != null) { MessageBox.Show("Ubicacion Encontrada"); ObtenerCampos(ubicaciones); } else { MessageBox.Show("Ubicacion no encontrada"); } }
private bool ExistenteEnLaBaseDeDatos() { Ubicaciones ubicacion = UbicacionesBLL.Buscar((int)IdNumericUpDown.Value); return(ubicacion != null); }
private bool ExisteEnLaBasedeDatos() { Ubicaciones ubicaciones = UbicacionesBLL.Buscar((int)UbicacionIdNumericupDown.Value); return(ubicaciones != null); }
private bool ExisteEnLaBaseDeDatos() { Ubicaciones ubicacion = UbicacionesBLL.Buscar(Convert.ToInt32(IdnumericUpDown.Value)); return(ubicacion != null); }