questo se non mi sbaglio controlla se la cartella è già esistente
chi può darmi una mano per unire il tutto?codice:Private Sub Command1_Click() Dim strNameFold As String Dim FSO As FileSystemObject Set FSO = New FileSystemObject 'Controlla se esiste la cartella DATI altrimenti la crea: If (FSO.FolderExists(App.Path & "\" & "DATI")) = False Then With FSO .CreateFolder (App.Path & "\" & "DATI") .CreateFolder (App.Path & "\" & "DATI\AnagClienti") ' ... ... ... End With strNameFold = FSO.GetFolder(App.Path & "\" & "DATI") MsgBox "La cartella DATI e le relative sottocartelle, sono state" & vbCr _ & "create con successo in " & strNameFold & ".", vbInformation, "Applicazioni........" End If Set FSO = Nothing End Sub

Rispondi quotando