I havent tested this but you could use a string array to hold all the file names. You can then pass the filepaths to a sub that copies and pastes to then next unused cells in your workbook. sonething like this:
Sub yourMacro()
Dim thePath(5) as string 'number of files you have - 1
thePath(0) = "C:FileDirectoryyourFile1"
Call openWorkBook(thePath(0))
'next file
thePath(1) = "C:FileDirectoryyourFile2"
Call openWorkBook(thePath(1))
''etc until all you files are copied. you can get fancy and do this w/a loop too
End Sub
''sub to open the current workbook
Sub openWorkBook(whatPath as string)
Workbooks.Open Filename:= whatPath
'your code to copy and paste here
whatPath.Close
End Sub
This should get you started
This message was edited by DavidVee on 2002-09-25 17:03