misssaraliz
Technical User
(This is a cross-post)
I already have a macro set up that will automatically export a report and save it in Excel. My problem is in trying to save the file with the date the export was run (mmddyy) listed in the filename. Here is an example of what my filename needs to look like (using today 2/20/02 as an example):
c:\my documents\Legislation 022002.xls
The following syntax works fine in VB:
"C:\My Documents\Legislation " & Month(Date) & Day(Date) & Year(Date) & ".xls"
But this same syntax doesn't work with the macro object in Access.
Any ideas???
I already have a macro set up that will automatically export a report and save it in Excel. My problem is in trying to save the file with the date the export was run (mmddyy) listed in the filename. Here is an example of what my filename needs to look like (using today 2/20/02 as an example):
c:\my documents\Legislation 022002.xls
The following syntax works fine in VB:
"C:\My Documents\Legislation " & Month(Date) & Day(Date) & Year(Date) & ".xls"
But this same syntax doesn't work with the macro object in Access.
Any ideas???