Hi,
I have written and tested code which works brilliantly (Not to brag) and I have sent the file to all in my organisation to use.
Part of the functionality is to email me a copy of their file. I then run another piece of code to copy data (theirs and mine I enter) from the emailed workbook to a master file.
But.....
The emailed file when opened changes the filename - "book1(01).xlsx" or "book1(001-1).xlsx" My code for the copy and paste states
workbooks("book1").Activate
Is there a way to instruct VBA to reactivate the variable filename I received on the email?
I'm guessing it might be nominating the temp file name as a string then using that in the activate line? But I don't know how to do that.
Any suggestions would be great
Thanks,
Johndinho
I have written and tested code which works brilliantly (Not to brag) and I have sent the file to all in my organisation to use.
Part of the functionality is to email me a copy of their file. I then run another piece of code to copy data (theirs and mine I enter) from the emailed workbook to a master file.
But.....
The emailed file when opened changes the filename - "book1(01).xlsx" or "book1(001-1).xlsx" My code for the copy and paste states
workbooks("book1").Activate
Is there a way to instruct VBA to reactivate the variable filename I received on the email?
I'm guessing it might be nominating the temp file name as a string then using that in the activate line? But I don't know how to do that.
Any suggestions would be great
Thanks,
Johndinho