Use the filepicker instead (below) - or see
Insert a selection of documents
Code:
Sub MergeDocs()
Dim rng As Range
Dim MainDoc As Document
Dim strFile As String
Dim Count As Long
With Application.FileDialog(msoFileDialogFilePicker)
.Title = "Pick files"
.AllowMultiSelect = True
If .Show <> -1 Then Exit Sub
Set MainDoc = Documents.Add
For Count = 1 To .SelectedItems.Count
strFile = .SelectedItems(Count)
Set rng = MainDoc.Range
With rng
.Collapse wdCollapseEnd
If Count > 1 Then
.InsertBreak wdSectionBreakNextPage
.End = MainDoc.Range.End
.Collapse wdCollapseEnd
End If
.InsertFile strFile
End With
Next Count
End With
MsgBox ("Files are merged")
lbl_Exit:
Exit Sub
End Sub