Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

opening report directly to Excel

Status
Not open for further replies.

ChrisBair

Technical User
Mar 17, 2004
32
US
How do you create a command button to open a report directly into excel, without exporting?

Thanks
 
Put this code into the command button

DoCmd.RunCommand acCmdOutputToExcel

Hope it works for you!
 
Hi

There are several variations available here

To begin, see docmd.outputTo, and docmd.TransferSpreadsheet in help, you could also open your result set simply as a query result grid, which LOOKS like an excel spreadsheet but is not, you can set it such that user cannot amend the output recordset,

depends on what you are trying to achieve

Regards

Ken Reay
Freelance Solutions Developer
Boldon Information Systems Ltd
Website needs upgrading, but for now - UK
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top