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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Sending Pivot Table to Excel

Status
Not open for further replies.

awarmplace

Programmer
May 4, 2001
10
US
I have a Pivot Table Form in Access that I am trying to send to Excel using a button. I would like for the user to be able to click a button and have the Pivot table itself export to excel not just the data.
 
Have you tried exporting the info from Access to Excel as XML data? That is supposed to bring over the structure as well as the data, which may include the pivot info you're looking for. I haven't tried it personally but it's worth a shot.

Of course, depending on the way in which the Excel file is to be used later, you could work the other way around...

Build your pivot table in Excel, either by connecting to the Access query results directly or via the regular export you've done of the data onto a separate "DATA" worksheet in the same workbook. Save it as a template and then make THAT the file that opens when you click the button in Access. Depending on how you approach it, either the normal exported data will go into the "DATA" worksheet and the pre-made pivot table will update with the requested info OR the pivot table will look at the current query results within Access and update. Either way, you'll wind up with a pivot table in Excel of your data. If you plan to use the Excel file away from the Access database later, I would recommend the 'separate DATA worksheet' method, since that would embed the raw data into the Excel file.

Hope this helps.
Michael
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top