
Sub nomefile()
Percorso = "C:" 'percorso con la finale
nomefile = Dir(Percorso)
i = 1
Do While nomefile <> ""
Cells(i, 1) = nomefile
i = i + 1
nomefile = Dir
Loop
End Sub
|
Sub nomefile()
Percorso = "C:" 'percorso con la finale
nomefile = Dir(Percorso)
i = 3
Do While nomefile <> ""
Cells(i, 3) = nomefile
i = i + 1
nomefile = Dir
Loop
End Sub |
Sub nome_file()
Percorso = Range("B7").Text
nomefile = Dir(Percorso)
i = 3
Do While nomefile <> ""
Cells(i, 3) = Left(nomefile, InStrRev(nomefile, ".") - 1)
i = i + 1
nomefile = Dir
Loop
End Sub
|
Sub nome_file()
percorso = Range("B7").Text
nomefile = Dir(percorso)
Set fs = CreateObject("Scripting.FileSystemObject")
If fs.folderexists(percorso) = True Then
i = 3
Do While nomefile <> ""
Cells(i, 3) = Left(nomefile, InStrRev(nomefile, ".") - 1)
i = i + 1
nomefile = Dir
Loop
Else
MsgBox "La cartella non esiste"
End If
End Sub
|
