private void datagdVoluntarios_MouseDoubleClick(object sender, MouseButtonEventArgs e) { _Voluntarios selec = datagdVoluntarios.SelectedItem as _Voluntarios; _VoluntariosLN voluntario = new _VoluntariosLN(); idVol = selec.idVoluntarios; WinAddVoluntario nWinAddVoluntario = new WinAddVoluntario(); System.Windows.Forms.Integration.ElementHost.EnableModelessKeyboardInterop(nWinAddVoluntario); nWinAddVoluntario.txtNombres.Text = selec.nombres; nWinAddVoluntario.txtApellidos.Text = selec.apellidos; nWinAddVoluntario.txtDireccion.Text = selec.direccion; nWinAddVoluntario.txtTelefono.Text = selec.telefono; nWinAddVoluntario.txtCorreo.Text = selec.correo; nWinAddVoluntario.txtNombreEmergencia.Text = selec.personaEmergencia; nWinAddVoluntario.txtTelEmergencia.Text = selec.telefonoEmergencia; nWinAddVoluntario.txtUniversidad.Text = selec.universidad; nWinAddVoluntario.cmbDepartamento.Text = selec.nombreD; nWinAddVoluntario.cmbMunicipio.Text = selec.nombreM; nWinAddVoluntario.btnGuardar.Visibility = Visibility.Hidden; nWinAddVoluntario.getId(idVol); nWinAddVoluntario.ShowDialog(); fillDataGrid(); }
private void btnPlus_Click(object sender, RoutedEventArgs e) { WinAddVoluntario nWinAddVoluntario = new WinAddVoluntario(); _VoluntariosLN voluntario = new _VoluntariosLN(); System.Windows.Forms.Integration.ElementHost.EnableModelessKeyboardInterop(nWinAddVoluntario); nWinAddVoluntario.btnModificar.Visibility = Visibility.Hidden; nWinAddVoluntario.ShowDialog(); fillDataGrid(); }