Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Import and reading from batch files
Message
From
02/10/2000 16:24:43
 
 
To
02/10/2000 13:49:16
Jacci Adams
Lindsay-Adams Consulting
Louisville, Ohio, United States
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00421332
Message ID:
00423724
Views:
16
>Hi Ed,
>
>
>>No, including 'D' gets both files and subfolders that are not hidden or system.
>
>What is the syntax you are using? For instance I want to get a list of all the .DBF files from my default directory down.
>
>I've tried the following and it only returns the names of the files in the default folder/directory (e:\vfe6\adev\alert\), and lnTotalSheets = 3 not the 7 it should return:
>
>lcSheetDir = "e:\vfe6\adev\alert\"
>
>lcFileName = lcSheetDir+ "*.DBF"
>lnTotalSheets = ADIR(laDir, lcFileName, "D")
>
>I've checked the file attributes and it should include them, they are not system or hidden. I've also noticed that if there aren't any files of the type you are looking for in the default folder lnTotalSheets = 0.
>
>I would appreciate insight into this, since you say it should work.
>

By limiting the file mask to *.DBF, it can't find anything not ending in *.DBF; the following works under my Win2K workstation:

? ADIR('F:\WINNT\*.*','D')

this returns 100 entries, some of which are folders. It is not recursive - it will not traverse subdirectories.
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Previous
Reply
Map
View

Click here to load this message in the networking platform