public void CargarDatos() { try { DataTable dt = new HCSoft.POS.UnidadesMedida().Consulta(unidadId); if (dt.Rows.Count > 0) { this.txtDescripcion.Text = dt.Rows[0]["nombre"].ToString(); } } catch (Exception) { throw; } }
protected void CargarGrilla() { try { DataTable dt = new HCSoft.POS.UnidadesMedida().Listar(); if (dt.Rows.Count > 0) { this.GrillaUnidadMedida.AutoGenerateColumns = false; this.GrillaUnidadMedida.AllowUserToAddRows = false; this.GrillaUnidadMedida.DataSource = dt; } } catch (Exception) { throw; } }