Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Removing A Directory
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00608966
Message ID:
00609134
Views:
29
>>>do u know how I can get folder names within a directory?
>>
>>adir(laFolders, '*.*', 'D')
>
>The only problem with this is that you get all files and folders. The attribute parameter causes them to be included and does not exclude files with different attributes. Correct is
ADIR(laFolders, "", "D")
Using your example, a folder with 4 sub-folders returns 165 rows in the array. Using my method, it returns 6 (the four sub-folders, the folder itself, and its parent).

Sorry I thought Jeffrey was trying to get all Files and all Sub-Folders so that he could go through each and delete them with the appropriate method (delete file or rmdir).

My misunderstanding :)
Caroline
Previous
Reply
Map
View

Click here to load this message in the networking platform