Crear un directorio si no existe
13.03.2008
La siguiente función crea el directorio pasado (strDirectoryPath) si no existe.
Public Sub CheckDir(strDirectoryPath As String)
If Dir(strDirectoryPath)<>”" Then
MkDir strDirectoryPath
End if
End Sub
Empieza por hacer primero lo necesario, luego lo posible, y de pronto estará haciendo lo imposible.
La siguiente función crea el directorio pasado (strDirectoryPath) si no existe.
Public Sub CheckDir(strDirectoryPath As String)
If Dir(strDirectoryPath)<>”" Then
MkDir strDirectoryPath
End if
End Sub