Scheduling Access

Hi,

Im looking to schedule an access form to run automatically each morning. How can i achieve this?

Thanks
Seamus
Seamus2626Asked:
Who is Participating?

[Webinar] Streamline your web hosting managementRegister Today

x
 
Simon BallConnect With a Mentor Commented:
make the form the default startup form for a new copy of the db.

make it do some work and then close access

use windows scheduled tasks to open the DB.

if that gives you any grief, make a batch file which opens the db.. and call that from the scheduled task

batch file:

start "" "d:\mydatabase.mdb"
exit
0
 
Seamus2626Author Commented:
"make it do some work and then close access"


Thanks Sudonim, what do you mean by the above, i have set the form as the default on open and used the scehduler to open Access, how can i get it to run the form though?

Thanks
Seamus
0
 
Simon BallCommented:
1) make a copy of your db, and open the copy

2) make the form the default in (assuming Access 2007) by going to the microsoft button, access options, current db, and select Display form and chose the form you want

3) close and re-open the db

4) set up the form to do the work you want, and if necessary - to close the access application when done.. ( you can do this with the button wizard thingy, close database.  DoCmd.Quit)

5)  Test that works ok... then go to (assuming win xp) start, settings, control panel, scheduled tasks, add task

and browse to your new database.

set up the schedule... and run the task as a test.

0
Never miss a deadline with monday.com

The revolutionary project management tool is here!   Plan visually with a single glance and make sure your projects get done.

 
Simon BallCommented:
by opening the form it is running the form...

is there a button on the form that needs to be pressed?  if so, you'll have to add the button press event into the forms onload event
0
 
Seamus2626Author Commented:
Heyu Sudonim, been away from my desk. I sceduled Access to open and the macro to autoexec, the problem is the warning messages, even when the MDB opens, i need to press

"Open"

Then i get all the other warning buttons

How can i supress these?

Thanks
Seamus
0
 
Jeffrey CoachmanMIS LiasonCommented:
Can you provide a bit more info on these Mysterious "other warning buttons"?
(Possibly providing screenshots)

Try opening the DB and specifying the macro to be opened at the same time..
Create a shortcut to open the DB, with something like this as the Target:
"C:\Program Files\Microsoft Office\Office12\MSACCESS.EXE" "c:\YourFolder\YourDatabase.mdb" /x YourMacro

Obviously, you would substitute your specific path to your Access executable...

0
 
Jeffrey CoachmanConnect With a Mentor MIS LiasonCommented:
FWIW to suppress most *security* messages, the DB must be in a trusted location.

Office Button-->Access Options-->Trust Center-->Trust Center Settings-->Trusted Locations

0
 
Seamus2626Author Commented:
Thats what i am doing boag2000, but when the db opens, who clicks "Open". Also, the Macro is executing queries that have warning messages such as "You are about to paste 30 rows into a table"

Again. with no user, how can i surpress these messages, can i do that within the queries?

Thanks
Seamus
0
 
Seamus2626Author Commented:
Okay, ive put into the autoexec macro to ignore warnings, however, im still in the same place regarding the "Open" Button. So when the sceduler opens Access, it needs someone to press "open"

I couldnt find your path

Office Button-->Access Options-->Trust Center-->Trust Center Settings-->Trusted Locations

I use 2003

Thanks
Seamus
0
 
Jeffrey CoachmanMIS LiasonCommented:
Again, can you post the screenshot of this "Open" message?
What version of Access Please?
Doers this message appear on All database, For all users, on all computers, ...etc
0
 
Seamus2626Author Commented:
2003

Its the main warning when you open access, the security warning......
attached

Thanks
Seamus
Doc2.doc
0
 
Seamus2626Author Commented:
Got it sorted, turned the security to low
0
 
Jeffrey CoachmanMIS LiasonCommented:
Great.
0
 
Simon BallCommented:
you can supress the append and delete messages using

docmd.setwarnings false


turn them back on at the end of the script / button code etc with
docmd.setwarnings true
0
All Courses

From novice to tech pro — start learning today.