Solved

Export data from Access to Specific Excel cells

Posted on 2011-03-23
6
565 Views
Last Modified: 2012-05-11
Hi

I am currently using a transfer spreadsheet code to export a qry to a specific excel tab, however, I would like to export to a specific "starting" cell.

0
Comment
Question by:kwarden13
  • 3
  • 3
6 Comments
 
LVL 33

Expert Comment

by:Mike Eghtebas
ID: 35202306
-What version of access your are using?
- Will be the code runing to transfer data from a remote database or from the local database

Mike
0
 
LVL 33

Accepted Solution

by:
Mike Eghtebas earned 500 total points
ID: 35202329
Generally speading, a code like:

DoCmd.TransferSpreadsheet acExport,...

should do it. But a more relaible method is to define Excel object and assign the desired values in one or more cells in excel.

If you could describe your use, we can choose the best solution for you.

Mike
0
 

Author Comment

by:kwarden13
ID: 35202345
the local database

From access 2007 to excel 2007

right now I am using the below code

DoCmd.TransferSpreadsheet acExport, , "qryDelRepCAN", "J:\data\Manager\Test.xlsx", True, "Canada"

Canada is the named range
0
Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

 

Author Comment

by:kwarden13
ID: 35202359
the issues is the named range

So the qry data can either expand or contract depending on the data so I need a dynamic named range. However when I try to do this it still doesnt work
0
 
LVL 33

Expert Comment

by:Mike Eghtebas
ID: 35202385
I guess you have another question on this subject.

brb
0
 

Author Comment

by:kwarden13
ID: 35202418
yes i originally thought it was a seperate issue but i think they are linked
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

Over the years I have built up my own little library of code snippets that I refer to when programming or writing a script.  Many of these have come from the web or adaptations from snippets I find on the Web.  Periodically I add to them when I come…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
In Microsoft Access, learn the trick to repeating sub-report headings at the top of each page. The problem with sub-reports and headings: Add a dummy group to the sub report using the expression =1: Set the “Repeat Section” property of the dummy…

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

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now