Solved

Access 2007 macro output to excel sheet

Posted on 2011-03-01
4
1,044 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

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
MS Access Subform Unique Records Issue 14 37
Database maintenance 36 108
ORDER BY 7 38
VBA Delete sql "Too Few Parameters" 8 24
In a multiple monitor setup, if you don't want to use AutoCenter to position your popup forms, you have a problem: where will they appear?  Sometimes you may have an additional problem: where the devil did they go?  If you last had a popup form open…
As tax season makes its return, so does the increase in cyber crime and tax refund phishing that comes with it
Basics of query design. Shows you how to construct a simple query by adding tables, perform joins, defining output columns, perform sorting, and apply criteria.
In Microsoft Access, learn how to use Dlookup and other domain aggregate functions and one method of specifying a string value within a string. Specify the first argument, which is the expression to be returned: Specify the second argument, which …

733 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