Created
September 21, 2009 02:48
-
-
Save NigelThorne/190041 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sub InsertLotsOfFiles() | |
' | |
' InsertLotsOfFiles Macro | |
' Macro written 21/09/2009 by Nigel Thorne | |
' | |
Dim No_Of_Files As Integer | |
Dim kk25 As Integer | |
Dim File_Path As String | |
File_Path = "..." 'change this to the path you want to use. | |
With Application.FileSearch | |
.NewSearch | |
.LookIn = File_Path | |
.FileName = "*.*" | |
.SearchSubFolders = False | |
.Execute | |
No_Of_Files = .FoundFiles.Count | |
For kk25 = 1 To No_Of_Files | |
Selection.InsertFile FileName:=.FoundFiles(kk25), Range:="", _ | |
ConfirmConversions:=False, Link:=False, Attachment:=False | |
Next kk25 | |
End With | |
End Sub | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment