Database Password

D

Derick

Hi,
I've created a Front end and Back end Database in access
2000. The backend database is password protected. Now I
cant open my database from the front end. I've tried
various examples of code but still the same problem. I
need the password to protect the data from unautherised
access. Can anyone please help?

Thanks

Derick
 
B

Br1an_g

Derick,

If you cant open the database at all, and its due to the
password on the back end:
remove the password from the back end, then open the front
end database.

keep it open then apply a password to the back end again.

re-link your tables in the front end.

see if this helps

Brian
 
G

Guest

Type the code below into a new module


1. Open the Data.MDB in exclusive mode.
2. Unset the password using the current password.
3. Reset the password using the new password.
4. Close the Data.MDB.
5. Open the application file
7. Place the cursor anywhere in the code module then run
the following code. (Run menu).


function ChangePassword()

dim db as database
dim tdf as tabledef
set db = currentdb

For Each tdf In db.TableDefs
On Error Resume Next
tdf.Connect = "MS Access;PWD=" &
yournewpassword" ";DATABASE=C:\Path to MDB
YourDatabase.MDB"

tdf.RefreshLink
Next tdf

end function
 
L

Lunch

Sent the last post but forgot to put my name
-----Original Message-----
Derick,

If you cant open the database at all, and its due to the
password on the back end:
remove the password from the back end, then open the front
end database.

keep it open then apply a password to the back end again.

re-link your tables in the front end.

see if this helps

Brian

.
 
N

Nina

I assume you linked the front end to the back end and then
put a password on the back end. You need to do the exact
opposite.
Remove the links from the front end, put the password on
the back end, reinstall the links on the front end. If
you do it this way the password is saved in the front end
database.
Nina
 
D

Derick

Thanks to all, I will try it.

Derick
-----Original Message-----
Type the code below into a new module


1. Open the Data.MDB in exclusive mode.
2. Unset the password using the current password.
3. Reset the password using the new password.
4. Close the Data.MDB.
5. Open the application file
7. Place the cursor anywhere in the code module then run
the following code. (Run menu).


function ChangePassword()

dim db as database
dim tdf as tabledef
set db = currentdb

For Each tdf In db.TableDefs
On Error Resume Next
tdf.Connect = "MS Access;PWD=" &
yournewpassword" ";DATABASE=C:\Path to MDB
YourDatabase.MDB"

tdf.RefreshLink
Next tdf

end function
.
 
D

Derick

Hi
I've run the code but recieve an error "ISAM not found"
What could be the problem?

Derick
 

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