Creare un'intera struttura di Directory
Come creare velocemente un'intera struttura di directory.
Public Sub rMkDir(ByVal mdir As String)
Dim FSO As Object
Set FSO = CreateObject("Scripting.FileSystemObject")
If FSO.GetParentFolderName(mdir) <> "" Then
rMkDir FSO.GetParentFolderName(mdir)
On Local Error Resume Next
MkDir mdir
Set FSO = Nothing
End Sub
Private Sub Form_Load()
rMkDir "d:\Testing\Hello\How\Are\"
End
End Sub
Testato su: Windows 98, Windows Me, Windows 2000 Professional