Hi
I need to write a macro which will copy data from files which will have differing names into a master file. I know how to get the data from one file with a known name into the master, but don't know how to pick up the filename of the open file to use in the macro.
Perhaps GetOpenFileName or something similar or can the data be obtained from an open file nomatter what its name is?
I'm using the following at present:-
[VBA] Windows("Sharing test 1.xls").Activate
Range("C11:G21").Select
Selection.Copy
Windows("Sharing test Master.xls").Activate
ActiveSheet.Paste
[/VBA]
The filename Sharing test 1 may be anything.
Thanks
Jeff T