View Full Version : Error Messege when Exporting

03-30-2005, 10:10 AM
I am receiving the following error messege when trying to export to excel with the code.
Error: "There are too many rows to output, based on the limitation specified by the output format or by Microsoft Access"

Code: DoCmd.OutputTo acOutputQuery, "query1", "MicrosoftExcel(*.xls)", "path"

The table that I was attempting to output was 17000 rows and 14 columns, both seemingly well within excel's limits.

Additionally, I tried to export the same table and lost a couple hundred records. None of the fields are that large.

Any help would be greatly appreciated.


03-31-2005, 04:16 AM
Microsoft Access defaults to the Excel 5.0 specification for backward compatibility. Try using the TransferSpreadsheet method ....

DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel2000, "YourQuery", "C:\Test\YourFile.xls", True