Export report to Excel-subscript out of range (1 Viewer)

Jupie23

Registered User.
Local time
Today, 06:30
Joined
Nov 9, 2017
Messages
84
I have a report for work that has 2 subreports. The report is a list of names, with the number of calls they took, the number of errors they had, and their error ratio for the week. I made a button with a macro to export the report to Excel so the numbers can be copied and pasted to other spreadsheets. It is working well. I made a copy of the report and it's 2 subreports, and switched everything over to the appropriate queries to do the same thing for another team. Everything is exactly the same except each team is on a different table. The second report will open and show the correct data, but when I try to export to Excel I get "subscript out of range." and then Access shuts down. It will export to Word or as a text file with no problem, and the data doesn't have anything weird in it. Any thoughts on what could be going on and how to fix it?
 

arnelgp

..forever waiting... waiting for jellybean!
Local time
Today, 19:30
Joined
May 7, 2009
Messages
19,233
What code did you use in macro OutputTo or TransferSpreadsheet? Use transferspreadsheet if you can do it in macro do it in vba.
 

Jupie23

Registered User.
Local time
Today, 06:30
Joined
Nov 9, 2017
Messages
84
I have attached a screenshot of the macro. I have the exact same thing for the other report and it is working well. This one is giving me the error and shutting down Access. Thank you!
 

Attachments

  • Capture.JPG
    Capture.JPG
    27.5 KB · Views: 86

Users who are viewing this thread

Top Bottom