OutoutTo acQuery acFormayXLS

A

Adam P.

-----Original Message-----
How do you output different objects to different sheets
in one Excel file?

To answer my own question, the following will append
multiple queries to one sheet in excel:

DoCmd.TransferSpreadsheet acExport,
acSpreadsheetTypeExcel9, "File name", "File path\File
name.xls"

Or, you can use this code to make multiple sheets:

DoCmd.OutputTo acOutputQuery, "File name",
acFormatXLS, "File path\File name.xls"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top