Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Simple way to check for and create a directory in VB
Message
From
04/10/2001 11:18:40
 
General information
Forum:
Visual Basic
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00564166
Message ID:
00564195
Views:
15
>Hi,
>
>I know how to do this in VFP, but not too sure in VB - so, I'm hoping that someone will point me in the right direction. As an example. let's say that I want to check for the exisitence of apppath + '\Export' - and if the Export subfolder doesn't exist, then create it. What would be the best approach?
>
>TIA, Al

I'm not a VB guy, but you could use WSH. Lookup filesystemobject in MSDN, and you will see VB Script examples. There is a createFolder() method, and a folderExists() method.

Check out "The Windows Script Host, the FileSystemObject (Pt 3 of 5)" article at http://www.vfug.org (in November, 2000 newsletter) for VFP examples, which are easily ported to VB.

HTH,
Steve Gibson
Previous
Reply
Map
View

Click here to load this message in the networking platform