My supervisor asked me that whether an access table can be exported to their wanted directory. Currently, I am using
to export as an Excel file. I suppose it has to do with
Code:
outputFileName = CurrentProject.Path & "\Report002_" & tb_Year.Value & cmb_Quarter.Value & ".xls"
DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel9, "dbo_RP_SAMPLE_002", outputFileName, True
Application.FollowHyperlink outputFileName
MsgBox "Exported!", vbOKOnly
CurrentProject.Path
but I just copied and pasted from a source so I don't really understand how it works. Will someone clarify it and tell me how to export to the wanted destination?