>dbc2Convert = "\\tpdfiles\data\dfreeman\tip\data\rta\rta.dbc" >aTables = GetDBCTableNames(dbc2Convert) >for i = 1 to alen(aTables) >? aTables(i) >next > >************************************************************************** >function GetDBCTableNames() >lparameters myDBC >select objectname as tablename ; >from (myDBC) ; >where objecttype = "Table" ; >into array A1 >return A1 >>Why do I get an error that says A1 is not an array? The select produces 6 records.
DIMENSION laArray[1] dbc2Convert = "\\tpdfiles\data\dfreeman\tip\data\rta\rta.dbc" lnTables = GetDBCTableNames(dbc2Convert, @laArray) for i = 1 to lnTables ? aTables(i) next ************************************************************************** function GetDBCTableNames(myDBC, laArray) select objectname as tablename ; from (myDBC) ; where objecttype = "Table" ; into array laArray return _TALLY(that is not tested also) :-)