Solved

Access 2007 macro output to excel sheet

Posted on 2011-03-01
4
1,050 Views
Last Modified: 2012-08-13
I have a simple Macro in Access 2007 using the 'Output To' Action to Export a query to an Excel Spreadsheet.

Works perfectly.
However, what I need is to be able to specify to output that query to FileA.xlsx, Sheet 1.
The next query to FileA.xlsx, Sheet 2
The next query to FileA.xlsx, Sheet 3

do-able?
0
Comment
Question by:jn1480
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 3

Expert Comment

by:JAMcDo
ID: 35009592
Clarification please>

Have you 1 query or more than 1 query?

Or . . .

Is the same query reuslts sent to Sheet1, then Sheet2, then Sheet3, . . . in a cyclic manner?  If so, are you trying to track which sheet either was the last sheet or should be the next sheet?

J.
0
 

Author Comment

by:jn1480
ID: 35009619
No tracking needed.
No cycles.

I will literally hand input each query into the Macro myself (I am brand new to this, and fascinated with the automation Macros are going to provide me).

I will assign one action line in the macro to output queryA to sheet/tabA in FileA.xlsx
I will then assign the next action in the macro to output queryB to sheet/tabB still in FileA.xlsx
Then the next action in the macro to output queryC to sheet/tabC still in FileA.xlsx

I want to end up with 3 (and/or many more) query outputs all in the SAME XLSX workbook file, just on separate sheets.
0
 
LVL 74

Accepted Solution

by:
Jeffrey Coachman earned 250 total points
ID: 35009840

"do-able?"
Sure, but not easily with "Macros"

See this popular link:
http://www.experts-exchange.com/Microsoft/Development/MS_Access/Q_25141094.html

JeffCoachman
0
 

Author Closing Comment

by:jn1480
ID: 35333360
Didn't match my request entirely, but a great add to my personal knowledge - thanks!
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes a method of delivering Word templates for use in merging Access data to Word documents, that requires no computer knowledge on the part of the recipient -- the templates are saved in table fields, and are extracted and install…
Microsoft Access is a place to store data within tables and represent this stored data using multiple database objects such as in form of macros, forms, reports, etc. After a MS Access database is created there is need to improve the performance and…
Learn how to number pages in an Access report over each group. Activate two pass printing by referencing the pages property: Add code to the Page Footers OnFormat event to capture the pages as there occur for each group. Use the pages property to …
In Microsoft Access, learn different ways of passing a string value within a string argument. Also learn what a “Type Mis-match” error is about.

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question