Beispiel #1
0
 public void llenarCombo()
 {
     try
     {
         using (WsSistemaBancario.ComponenteServiceClient componente = new WsSistemaBancario.ComponenteServiceClient())
         {
             cmbPadre.DataSource    = componente.Componente_ObtenerTodos().ToList();
             cmbPadre.ValueMember   = "Id";
             cmbPadre.DisplayMember = "Nombre";
         }
     }
     catch (Exception)
     {
         MessageBox.Show("Error en cargar componentes", "Componentes");
     }
 }
Beispiel #2
0
 private void Listar_Componentes()
 {
     try
     {
         using (WsSistemaBancario.ComponenteServiceClient componente = new WsSistemaBancario.ComponenteServiceClient())
         {
             componentes_list = componente.Componente_ObtenerTodos().ToList();
             foreach (var p in componentes_list)
             {
                 dgvPermisos.Rows.Add(p.Nombre, p.Codigo, p.Estado);
             }
         }
     }
     catch (Exception)
     {
         MessageBox.Show("Error en cargar componentes", "Componentes");
     }
 }