Nightly Autorun Macro

M

Mike The Newb

Is there a way to have a Macro run every night, or at a specific time,
without the aid of my IT department? The process finishes with an export to
Excel and this must be accomplished as well during this pre-established kick
off.

Thanks for looking.

Regards,

Mike
 
S

Steve Schapel

Mike,

You can use Windows Task Manager to do this. The Command Line for the
scheduled task will be something like this...
"C:\Program Files\... PathToAccess\Msaccess.exe"
"C:\PathToDB\MyDB/mdb" /x NameOfMacro
 
M

Mike The Newb

Steve - thank you! First part working great.

The Excel export part is still a concern. How do I write a Macro to export
three separate queries into one pre-existing Excel file with three specific
tabs as the destination of these three exports?

The queries access two different data sources that require ODBC connections
and sign ons. This is specific to the Microsoft Access Marco and resulting
queries to be exported. Can this be accomplished as part of this overall task
that is autorun?

Thank you again!

Regards,
Mike
 
S

Steve Schapel

Mike,

I would assume you would need three separate TransferSpreadsheet actions
in your macro, one for each of the queries. You can specify the name of
the sheet of the Excel workbook via the Range argument of the
TransferSpreadsheet action.
 

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