I have a couple of queries that are run weekly. The results are exported to Excel and the Excel files are emailed to the user. I have this set up to run Every Monday at 5 AM so the user has the data is his inbox when he comes in to work. What I'd like to do is include in the VBA so the file name is changed after the email is sent to create a history of the files that were sent.
For example:
The Data is exported to Claim_Audit_Facilities and Claim_Audit_Professional Excel Spreadsheets and emailed to the User. After that is completed I want to change both file names to include the underscore and the rundate. So the filename would change to Claim_Audit_Facilities_12272017 and Claim_Audit_Professional_12272017.