private void Listar() { try { DgvListado.DataSource = NUsuario.Listar(); LblTotal.Text = "Total Registros: " + Convert.ToString(DgvListado.Rows.Count); } catch (Exception ex) { MessageBox.Show(ex.Message + ex.StackTrace); } }
private void Listar() { try { DgvListado.DataSource = NUsuario.Listar(); this.Formato(); this.Limpiar(); labelTotal.Text = "TOTAL DE REGISTROS:" + Convert.ToString(DgvListado.Rows.Count); } catch (Exception e) { MessageBox.Show(e.Message + e.StackTrace); } }
private void listar() { try { dvgUsuarios.AutoGenerateColumns = false; dvgUsuarios.DataSource = reglaUsuario.Listar(); foreach (DataGridViewRow fila in dvgUsuarios.Rows) { fila.Cells[3].Value = "********"; } toolStripStatusLabel1.Text = dvgUsuarios.RowCount + " Usuarios"; } catch (Exception ex) { ex.Message.ToString(); } }
//Metodo para Listar los Datos private void Listar() { try { //Llenamos el DataGrid con el metodo Listar de la Clase Ncategoria DgvListado.DataSource = NUsuario.Listar(); //Aplicamos el formato al datagrid con el metodo "Formato" this.Formato(); //Limpiamos campos this.Limpiar(); //Le asignamos texto al Label total Registros LblTotal.Text = "Total Registros: " + Convert.ToString(DgvListado.Rows.Count); } catch (Exception ex) { MessageBox.Show(ex.Message + ex.StackTrace); } }
private void Listar() { DgvUsuario.DataSource = NUsuario.Listar(); }