Solved

Run scheduled task with Access Database that has a password

Posted on 2011-09-14
3
482 Views
Last Modified: 2012-05-12
Hi,

I have scheduled tasks that run macro's in an Access database. However recently I have had to put a password on the database. The scheduled tasks cannot run anymore. How do I get around this?

Thanks,
0
Comment
Question by:mcs26
3 Comments
 
LVL 84

Accepted Solution

by:
Scott McDaniel (Microsoft Access MVP - EE MVE ) earned 500 total points
ID: 36535032
There's no way to directly open a password protected database from the commandline, so you have to build a "launcher" database that does nothing more than open your password-protected db, and then call the "launcher" database from your task.

The launcher can be nothing more than a single form database. Open that form on startup and include code like this in the Open or Load event of that form:

Dim db As DAO.Database
Set db = DAO.OpenDatabase("full path to your password-protected database", False, False, ";PWD=YourPassWord")

===================================

Here's the MS atricle about the method:
http://support.microsoft.com/kb/209953

Note the code example above also opens a Recordset, but you could of course leave out that portion of the code.

0
 
LVL 10

Expert Comment

by:plummet
ID: 36535035
Hi MCS,

How are you kicking off the tasks? I have a few ideas but it depends...

Cheers
0
 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 36537093
...What kind of password system are you using?

Access' built in password utility? ... or is this something you made on your own?
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction When developing Access applications, often we need to know whether an object exists.  This article presents a quick and reliable routine to determine if an object exists without that object being opened. If you wanted to inspect/ite…
Describes a method of obtaining an object variable to an already running instance of Microsoft Access so that it can be controlled via automation.
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question