How to export to Excel

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have an Access database which contains information on my customers, what
sites they have, and what members of my staff work at those sites.

I want to export some of this data to an Excel spreadsheet. I want to create
a sheet for each site that I manage with a list of every member of staff that
works at that site but I have absolutely no idea how to do this or whether
this is even possible.

Is there anybody that could give me some guidance on this problem?

Thanks

David
 
look in help for the TransferSpreadsheet action. Its purpose is to import
and export Excel spreadsheets.
 
Put the following in the "click event". This docmd can be repeated as many
times as you like. I have included a string to save the date and time the
file is saved.


Dim sToday As String

sToday = Format(Now, "yyyy.mm.dd hh.mm")

DoCmd.TransferSpreadsheet acExport, _
acSpreadsheetTypeExcel9, "QUERY", _
"C:\DESTINATION - " & sToday & ".xls", True, "SHEET NAME"
 

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