Access to Excel

G

Guest

I'm trying to export/import the results of an Access parameter query to a
particular range of cells in a pre-existing Excel worksheet. Can this be done
programatically, and if so, is it best to do it from within Access or within
Excel. I've tried several methods (DoCmd.TransferSpreadsheet, Export from the
file menu, etc.) but they just create a new worksheet or want to overwrite my
existing sheet.

So far, the only way I've been able to do it is to run a make table query in
Access to create a temporary table, then open the Excel worksheet, select the
beginning cell in the range, and go through all the steps to import the
temporary table from access (a simple 48 step process that my users won't be
able to accomplish)

I would like to automate the process, but last night was Friday night, so my
capacity to figure this out seems to be somewhat diminished right now

Any thoughts?

Thanks
 
I

Ian

You can DoCmd.TransferSpreadsheet, Export to a new spreadsheet, then use VBA
to transfer the data to the existing sheet.

I've been able to manage somethign similar, but it took me a lot of effort
as I'm not familiar with Access and writing Excel VBA to run in Access
differs from the same procedure in Excel.

Good luck.

Ian
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top