Sub Auto_open() Dim StDateiname As String Dim Dateiform As String Dim InI As Long, TotFiles As Long Dim Suchpfad As String Dim OldStatus As Variant Suchpfad = InputBox("Geben Sie den Ordner an, der durchsucht werden soll.", "Pfad definieren", Application.DefaultFilePath) If Suchpfad = "" Then Exit Sub Dateiform = InputBox("Geben Sie den Dateityp an der gesucht werden soll", "Dateierweiterung", "*.xls") If Dateiform = "" Then Exit Sub Application.ScreenUpdating = True OldStatus = Application.StatusBar With Application.FileSearch .LookIn = Suchpfad ' Suchverzeichnis .SearchSubFolders = True ' suchen auch in Unterverzeichnis .Filename = Dateiform If .Execute() > 0 Then TotFiles = .FoundFiles.Count Application.StatusBar = "Total " & TotFiles & " gefunden" For InI = 1 To .FoundFiles.Count Application.StatusBar = "Datei: " & InI & " von " & TotFiles StDateiname = Mid(.FoundFiles(InI), InStrRev(.FoundFiles(InI), "\") + 1) ActiveSheet.Hyperlinks.Add Anchor:=Cells(InI, 1), _ Address:=.FoundFiles(InI), TextToDisplay:=StDateiname ' Hyperlink Cells(InI, 2) = FileLen(.FoundFiles(InI)) ' DateigrӇe Cells(InI, 3) = FileDateTime(.FoundFiles(InI)) ' Dateidatum Next InI End If End With Application.StatusBar = OldStatus Application.ScreenUpdating = True End Sub