I'm tring to use this function, that I found here:
Sub CreateFolderTree(strTempPath)
On Error Resume Next
If strTempPath <> "" Then
If Not objFSO.FolderExists(objFSO.GetParentFolderName(strTempPath)) Then
Call CreateFolderTree(objFSO.GetParentFolderName(strTempPath))
Else
objFSO.CreateFolder(strTempPath)
End If
Else
' Lowest Directory
End If
On Error GoTo 0
End Sub
I call it like this:
Call CreateFolderTree(strDestinationRoot & strSourceApp)
The vars look something like this:
strDestinationRoot = "\\UNCServer.tld\Directory\" & strUserName & "\Something\Something"
strSourceApp = "\Folder\From Root"
Unfortunatly, I have to run it twice inorder for it to create the directory tree in my example.
Can any one lend some help?
Sub CreateFolderTree(strTempPath)
On Error Resume Next
If strTempPath <> "" Then
If Not objFSO.FolderExists(objFSO.GetParentFolderName(strTempPath)) Then
Call CreateFolderTree(objFSO.GetParentFolderName(strTempPath))
Else
objFSO.CreateFolder(strTempPath)
End If
Else
' Lowest Directory
End If
On Error GoTo 0
End Sub
I call it like this:
Call CreateFolderTree(strDestinationRoot & strSourceApp)
The vars look something like this:
strDestinationRoot = "\\UNCServer.tld\Directory\" & strUserName & "\Something\Something"
strSourceApp = "\Folder\From Root"
Unfortunatly, I have to run it twice inorder for it to create the directory tree in my example.
Can any one lend some help?