Excel report dump

  • Thread starter Thread starter Nick
  • Start date Start date
N

Nick

Does anyone know a way to give the user the option of letting a user launch
a query and have it dump into an excel spreadsheet all with the push of one
button from a form? The way I have it set up right now is the user actually
launches the query from the form, enters date criteria, and the query
displays the reports in Access format, from which they have to dump to
Excel. I would really rather them not see the Access data at all.

Thanks. Any help with this issue would be greatly appreciated.

Nick
 
Nick,

Lookup the TransferSpreadsheet function in Help. Use a pop-up form called
PFrmDateCriteria to enter your date criteria. Here's a skelton of what you
need ---

Put code like this in the OnClick event of a button:

DoCmd.OpenForm "PFrmDateCriteria",,,,,acDialog
DoCmd.transferSpreadsheet............
DoCmd.Close acForm, "PFrmDateCriteria"

On PFrmDateCriteria, put this code either in the AfterUpdate event of the date
field or iin the OnClick event of an OK button:

Me.Visible = False


--
PC Datasheet
A Resource for Access, Excel and Word Applications
(e-mail address removed)
www.pcdatasheet.com

· Design and basic development for new applications
· Additions, Modifications and "Fixes" for existing applications
· Mentoring for do-it-yourselfers who want guidance
· Complete application design and development
· Applications Using Palm Pilot To Collect Data And
Synchronize The Data Back To Access Or Excel
 
Back
Top