public void actualizardatagriew(string algo) { DataTable dt = mo.consultaLogica3(algo); Dgb_encabezadoProductosP.DataSource = dt; int head = 0; while (head < mo.contarCampos(tabla)) { Dgb_encabezadoProductosP.Columns[head].HeaderText = aliasC[head]; head++; } }