Open Workbook
Dim i As Long
With Application.FileDialog(msoFileDialogFilePicker)
.AllowMultiSelect = True
.InitialFileName = ThisWorkbook.Path & Application.PathSeparator &
"*.xls"
If .Show = -1 Then
For i = 1 To .SelectedItems.Count
Workbooks.Open .SelectedItems(i)
Next i
End If
End With
--
__________________________________
HTH
Bob
"Arnie" wrote in message
...
within my macro i wqant a message box to come up requesting the user to
either type in a file name or paste it and then use that file name to open
the file
also a way of selecting how many files i want the macro to run on
for example run 1 i may have 3 files i want to run the macro on so i need
the message box to ask me three times for each filename
the next time i run it i may need to use 10 files to run the same macro on
supplying 10 different filenames
the files will always be located in the same folder as the spreadsheet i
am
running the macro on.
thanks in advance
Arnie
|