Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Simple way to check for and create a directory in VB
Message
General information
Forum:
Visual Basic
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00564166
Message ID:
00564475
Views:
18
>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

You could use the fso but why do several lines of code when one will do?
If Dir(App.Path & "\Export", vbDirectory) = "" Then MkDir App.Path & "\Export"
~Joe Johnston USA

"If ye love wealth better than liberty, the tranquility of servitude better than the animated contest of freedom, go home from us in peace. We ask not your counsel or arms. Crouch down and lick the hands which feed you. May your chains set lightly upon you, and may posterity forget that ye were our countrymen."
~Samuel Adams

Previous
Next
Reply
Map
View

Click here to load this message in the networking platform