Create a folder with CREATEDIRECTORY. (Original)
Private submmand1_click ()
Private Declare Function CreateDirectory LIB "Kernel32" Alias "CreateDirectorya" (Byval LPPathname As String, LPSecurityAttributes as security_attributes) As long
Dim attribut As SECURITY_ATTRIBUTESattribut.nLength = Len (attribut) attribut.lpSecurityDescriptor = & O0attribut.bInheritHandle = False Dim counter As Long Dim tnew As String Dim onew As String Dim i As Long Dim lnew As Long Dim tx As String Dim mi As String Dim minstra As Long Dim A AS String A = InputBox ("Please enter the folder name you want to create", "Create Folder Name") Counter = 0 if Right (A, 1) <> "/" THEN A = A & "/ "End if lnew = len (a) for i = 1 to LNEW TX = Left (a, i) ife (tx)> 3 Then Mi = Right (TX, 1) IF mi =" / "THEN CALL CREATEDIRECTORY (TX Attribut) end if endiff i
End Sub