Hi,
To copy a file, use FileCopy
Dim SourceFile, DestinationFile As String
SourceFile = "SRCFILE" ' Define source file name.
DestinationFile = "DESTFILE" ' Define target file name.
FileCopy(SourceFile, DestinationFile) ' Copy source to target.
source: http://msdn.microsoft.com/fr-fr/libr...=vs.90%29.aspx
To choose a file, useFileDialog(msoFileDialogFilePicker)
http://msdn.microsoft.com/en-us/libr...ice.11%29.aspx
To choose a folder it is similar but use FileDialog(msoFileDialogFolderPicker) instead of FileDialog(msoFileDialogFilePicker)
To loop on names use something like
i=0
While (Not (IsEmpty(Range("A12").Cells(1, 1 + i)))) And (i < 1000)
do the copy
i = i + 1
Wend
where A12 is the first name location, the test i<1000 is optional
ben
Bookmarks