Run Access File Daily using Task Scheduler


Can someone guide me please in very simple steps how to run an Access database daily using Task Scheduler

I have tried this C:\Program Files (x86)\Microsoft Office\Office15\MSACCESS.EXE "D:\pathtoyourAccddbfile\file.accdb"

but nothing

The user was Admin...

Again I would be very grateful if it is simple clear steps

Many Thanks
M SOSAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Jim Dettman (Microsoft MVP/ EE MVE)President / OwnerCommented:
That's pretty much it....maybe the command in quotes as well:

"C:\Program Files (x86)\Microsoft Office\Office15\MSACCESS.EXE" "D:\pathtoyourAccddbfile\file.accdb"

 and calling it from a batch file possibly (and then calling the batch file from Task Scheduler), but what you have should work.

 What happens exactly?  Also understand that as a "foreground application", you must have a user logged in so a desktop, printers, and drive mappings are available.

 It won't run in a logged out state if that's what your looking for.   It will run with the station locked, but not logged out.


Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
M SOSAuthor Commented:
Nothing happened

The user is logged on to terminal server session, I created the task to run... I gave the task the appropriate admin rights to run ...the file is on a mapped drive H:\pathtoyourAccddbfile\file.accdb

Nothing happened when it runs

Any solution

Jim Dettman (Microsoft MVP/ EE MVE)President / OwnerCommented:
I would suggest creating a batch file.   Try executing that outside of the scheduler.  Once you have that working, then call the batch file from the scheduler.

<< I gave the task the appropriate admin rights to run >>

 You must be running under the account of the logged in user.

IT Pros Agree: AI and Machine Learning Key

We’d all like to think our company’s data is well protected, but when you ask IT professionals they admit the data probably is not as safe as it could be.

M SOSAuthor Commented:
I do not know how to create a patch file which run this access file?

I am not too sure
Dennis JohnsonIT technicianCommented:
After manually running the command from within task scheduler and refreshing the list after 1-2 seconds (important), what is the value of the column Last Run Result?
Scott McDaniel (Microsoft Access MVP - EE MVE )Infotrakker SoftwareCommented:
I do not know how to create a patch file which run this access file?
Not a "patch" file, but rather a "batch" file. That's a file Windows can execute that will run the commands you have listed in the file. In your case, it would be as simple as creating a file with the .bat extension, and copying that line into that file. Then "run" that file by double-clicking it in Windows Explorer. If it runs correctly from there, then use the Task Scheduler to launch the .bat file.

Here's some more information on Batch Files:
Jim Dettman (Microsoft MVP/ EE MVE)President / OwnerCommented:
<<I do not know how to create a patch file which run this access file? >>

On the desk top, right click and select "new text Document".

Rename it to myapp.bat

Say yes that you want to change the extension

right click on the file and select edit

Type in (or cut and paste) the command you had in the task scheduler.


Now double click.  You should see a window, Access start, and your app.  If not, then something is wrong with the command.

If you do, change task scheduler so that it now tries to execute the myapp.bat file.

M SOSAuthor Commented:
I do not agree with that

I stopped responding partially because have given up
Dennis JohnsonIT technicianCommented:
I asked what was the value of the Last Run Result column, in order to start troubleshooting from somewhere, but you didn't respond.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Windows Server 2008

From novice to tech pro — start learning today.