with thisform.grid1 .ColumnCount = -1 .RecordSourceType = 1 .RecordSource = tcCursorAlias endwithWith a ColumnCount = -1 VFP will build the grid by itself.
> LPARAMETERS tcCursorALias > Thisform.GriD1.RecordSourceType = 1 > Thisform.GriD1.RecordSource = tcCursorAlias > Thisform.GriD1.ColumnCount = AFIELDS(aFlds,tcCursorALias) > FOR lni=1 TO Thisform.GriD1.ColumnCount > ?Thisform.GriD1.Columns(lni).ControlSource > ENDFOR >>