private void BuscarEstudiante_Click(object sender, EventArgs e) { var student = EstudiantesBll.Buscar(Convert.ToInt32(IdEsttextBox.Text)); if (student != null) { NombreEstudianteTextBox.Text = student.Nombres; } }
private void Buscarbutton_Click_1(object sender, EventArgs e) { int id; Estudiantes estudiante = new Estudiantes(); id = Convert.ToInt32(IdnumericUpDown1.Value); Limpiar(); estudiante = EstudiantesBll.Buscar(id); if (estudiante != null) { MessageBox.Show("Persona Encontrada"); LlenaCampo(estudiante); } else { MessageBox.Show("Persona no Encontrada"); } }
private bool ExisteEnBaseDeDatos() { Estudiantes estudiante = EstudiantesBll.Buscar((int)IdnumericUpDown1.Value); return(estudiante != null); }