How to Backup (run code) weekly and monthly

MsLady

Traumatized by Access
Local time
Today, 15:27
Joined
Jun 14, 2004
Messages
438
I have some sql statements that copy data from my tables into tables in a backup database after it deletes existing data from these backup tables.

I also have another code i got from here (thanks Ghudson) that Zips my entire database.

My backup procedures are pretty much set. I currently have these codes attached to onClick events of 2 command button (one for appending tables and one for ziping). But i don't know how to do this automatically..periodically. Meaning, every week, and month.

Want i want is to do run the code (mulitple sql to append the data into my backup tables) every saturday at 12midnight.
And run another procedure that zips my entire database (forms/queries/reports) every 1st a new Month - Monthly.


How can i implement this periodically? Can anyone help me? I have spent 2 days searching the forum now, haven't found much. Any suggestions, code, links, tutorials, will be greatly appreciated. Thank you :)
 
You can use Scheduled Tasks on a PC to open an Access database to run whatever needs to run. You will need to build the db to automatically run the required code either through the startup or a macro.
 
antomack said:
You will need to build the db to automatically run the required code either through the startup or a macro.

Hi antomack, how do i do this?:)
 
Crate and use an AutoExec macro to run your function when the db is first opened. Anything in a macro named "AutoExec" will run first with the db is opened.
 
ghudson said:
Crate and use an AutoExec macro to run your function when the db is first opened. Anything in a macro named "AutoExec" will run first with the db is opened.
Thanks ghudson. I think i know how to do Autoexec on startup, but what i don't know is how to have the code run weekly and another code run monthly. Or where do i specify for my code to do this? What do you suggest?
 

Users who are viewing this thread

Back
Top Bottom