private void RegistrarUsuario_Load(object sender, EventArgs e) { NUser = new NUsuario(); comboMecanico.DataSource = mecanico.ShowMecanico(); comboMecanico.ValueMember = "id"; comboMecanico.DisplayMember = "nombre"; dataGridView1.DataSource = NUser.ShowUsuarios(); }
private void PReparacion_Load(object sender, EventArgs e) { reparacion = new NReparacion(); comboMecanico.DataSource = mecanico.ShowMecanico(); comboMecanico.ValueMember = "id"; comboMecanico.DisplayMember = "nombre"; comboVehiculo.DataSource = vehiculo.ShowVehiculos(); comboVehiculo.ValueMember = "id"; comboVehiculo.DisplayMember = "placa"; dataGridView1.DataSource = reparacion.ShowReparacion(); }
private void button1_Click(object sender, EventArgs e) { mecanico.RegistrarMecanico(textCodigo.Text, textNombre.Text, textCI.Text, textDireccion.Text, textTelefono.Text); MessageBox.Show("Se registro correctamente"); dataGridView1.DataSource = mecanico.ShowMecanico(); }
private void PMecanico_Load(object sender, EventArgs e) { mecanico = new NMecanico(); dataGridView1.DataSource = mecanico.ShowMecanico(); }