Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Special Folder Code Doesn't Work
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00730390
Message ID:
00730394
Views:
17
Try this
oFSO = CREATEOBJECT("scripting.filesystemobject")
oFolder = oFSO.GetFolder(cBaseFolder)
oSubFolders = oFolder.SubFolders
FOR EACH oSubFolder IN oSubFolders
  ? oSubFolder.Path
  oFiles = oSubFolder.Files
  FOR EACH oFile IN oFiles
    oFile.Delete()
  ENDFOR
ENDFOR
>Why doesn this work?
>
>On the line after the comment, I get the error
>"Member SUBFOLDERS does not evaulate to an object"
>
>There are 4 subfolders, but this code doesnt see them.
>Anyone know why?
>
>
--sb--
Previous
Reply
Map
View

Click here to load this message in the networking platform