Probably the most easy question here...

  • Thread starter Thread starter JasonS
  • Start date Start date
J

JasonS

Good morning / evening!
What's my ploblem, I created a database in MS Access, with 3 crosstab
queries in it. I want the results of those queries to be put in one Excel
file, on one worksheet, in new rows. It's easy when I use
TransferSpreadSheet method for the first query, but I don't know how many
cells (rows and columns) will it use. My question is, how to find out using
VBA, which cell is the last one, because I have to append results of the
second and third query to it. I don't know how to describe range of cells
when I'm not sure where cells on my worksheet are ending...

Thank you for your help,
with best regards, Jason
 
cLastRow = Cells(Rows.Count,"A").End(xlUp).Row

this tests column A.

If you are creating an Excel instance from Access, you will need the
appropriate object qualifiers.
 

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

Back
Top