General information
Category:
Coding, syntax & commands
Hi Siva,
Try something like this:
*-- find out where the spread sheets we need to track are located
ThisForm.cSheetDir = GETDIR("f:\private\sheets\vs","Stock Sheets?")
*-- Create an array of all the spreadsheets in the selected directory
lcName = ThisForm.cSheetDir+ "*.xls"
This.nTotalSheets = ADIR(laDir, lcName)
DIMENSION laList[This.nTotalSheets] && dimension the list array
FOR lnCnt = 1 to This.nTotalSheets
lcFile = laDir[lnCnt,1]
APPEND FROM &lcFile CVS
ENDFOR
You'll have to play with this to get it to work the way you need it to.
HTH,
Jacci
>Hi everyone,
> I am trying to read records from a batch of files located in a particular dir. I am able to get the dir name from the command getdir(). However, I would like to know the syntax(list of commands) that would enable me to open all the files that are situated in this dir and input them to a vfp table. The files are in comma seperated format. Any help is greatly appreciated. Thanks in advance.
>Regards,
> Siva
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only