Photo Gallery
Member List
Search
Calendars
FAQ
Ticket List
Log Out
Forums
Register
Login
My Profile
Inbox
Address Book
My Subscription
My Forums
fCreateFolder Function
Logged in as: Guest
arrSession:exec spGetSession 2,16,37662
Active Users: There are
0
members and
0
guests.
Users viewing this topic: none
Printable Version
All Forums
>>
[Scripting]
>>
Post a VBScript
>> fCreateFolder Function
Do you like VisualBasicScript.com? Link to us and help spread the word about our forum. Thanks!
Page:
[1]
Login
Message
<< Older Topic
Newer Topic >>
fCreateFolder Function -
9/12/2006 3:51:49 AM
DiGiTAL.SkReAM
Posts: 1146
Score: 7
Joined: 9/6/2005
From: Florida, USA
Status:
offline
Since there have been a few posts concerning creating multiple folders, or even a whole path, I thought I'd post this function.
Function fCreateFolder(sFolderPathToCreate) ' This function checks for the existence of a folder. If it does not exist, ' it will create the folder and any parent folders that do not exist, as well. ' It can handle either UNC paths or drive letter paths. If Trim(sFolderPathToCreate) <> "" Then If oFSO.FolderExists(sFolderPathToCreate) Then Exit Function fCreateFolder(oFSO.GetParentFolderName(sFolderPathToCreate)) oFSO.CreateFolder(sFolderPathToCreate) End If End Function
_____________________________
"Would you like to touch my monkey?" - Dieter (Mike Meyers)
"It is better to die like a tiger, than to live like a pussy."
-Master Wong, from Balls of Fury
Post #: 1
If you found our site useful please link to us
<a href="http://www.visualbasicscript.com">VisualBasicScript.com</a>
.
All Forums
>>
[Scripting]
>>
Post a VBScript
>> fCreateFolder Function
Page:
[1]
Jump to:
Select a Forum
All Forums
----------------------
[Welcome]
- - Forum Rules
- - Test Posting Messages
- - New Member Area/Introduction
[Scripting]
- - WSH & Client Side VBScript
- - WSH & Client Side VBScript Tutorial
- - Post a VBScript
- - Windows PowerShell
- - ASP
- - ASP.NET
- - Windows Script Components
[General Forum]
- - Other Programming/Scripting Languages
- - Suggestions & Feedback
- - Off-Topic Lounge
New Messages
No New Messages
Hot Topic w/ New Messages
Hot Topic w/o New Messages
Locked w/ New Messages
Locked w/o New Messages
Post New Thread
Reply to Message
Post New Poll
Submit Vote
Delete My Own Post
Delete My Own Thread
Rate Posts
Forum Software ©
ASPPlayground.NET
Advanced Edition
2.5.5 ANSI