Security Wizard Locked ALL Db's

B

Bob

After running the Security Wizard to "Secure" a single
database I have found ALL of the Access databases I try
to open LOCKED!

I'm prompted to enter a Username and Password for every
db, even db I did not protect.

Is this by design ?? Can I rool back the system to a
prior point with the system restore feature to remove
this ??

I have databases on a server and other users are able to
access just fine, but everything from this workstation
wants a userid/password.

Thank you for any assistance!
 
G

Graham R Seach

Bob,

It seems you took all the right actions - except one! You forgot to create a
new Workgroup file before you started.

At this point, you have two options.

The first option (and one I know you're not going to like), is to remove all
the security you've just added, then start again (making sure to create a
new workgroup file before you start).

The second option is to make a copy of the current System.mdw file, rename
it, then fire up the secured database using it.
1. Open any code module in the secured database.
2. Display the Immediate window (View --> Immediate Window).
3. In the Immediate Window, enter the following, then hit the Enter key:
?dbengine.SystemDB
You should get something like this:
C:\PROGRA~1\COMMON~1\System\SYSTEM.MDW
This is the path to the current System.mdw file (the one you're about to
copy).
4. Enter the following in the Immediate window, then hit the Enter key:
?access.SysCmd(acSysCmdAccessDir)
You should get something like this:
C:\Program Files\Microsoft Office\Office\
5. Close Access.
6. Copy the System.mdw file to a place where all users can get at it.
7. Rename the copied System.mdw file to something else (typically, this
would be the same name as the mdb file).
8. Make a shortcut to your mdb file:
a). Open Windows Explorer.
b). Locate your database (*.mdb).
c). Right-click the mdb file, and select Create Shortcut from the
context menu.
d). Move the newly-created shortcut to your Desktop.
9. Right-click the shortcut, and select Properties from the context menu.
10. Select the Shortcut tab.
11. Place the cursor at the far left of the Target field, then enter the
path you got in Step 4. Then append "msaccess.exe", and enclose it in
double-quotes. It should look like this:
"C:\Program Files\Microsoft Office\Office\msaccess.exe"
12. Make sure there's a space between what was already in the Target field,
and the path you added in Step 10.
13. Place the cursor at the far-right of the Target field, then enter
"/wrkgrp", a space, plus the path you to the new (renamed) Workgroup file,
and enclose it in double-quotes. It should look like this:
/wrkgrp "C:\myDatabase\myDb.mdw"
14. The whole Target string should look like this:
"C:\Program Files\Microsoft Office\Office\msaccess.exe"
"c:\myDatabase\myDb.mdb" /wrkgrp "C:\myDatabase\myDb.mdw"
15. Click OK.
16. Just to check that all went well, double-click the shortcut, and enter
your username and password.
17. Close Access.
18. Remember in Step 6 when you copied the mdw file? Well now you have to
replace the original one with something that doesn't have security in it.
Pinch one from somebody else in the office, and simply copy it over the top
of the one whose address was discovered in Step 3.

Now every time you want to use this database, you'll have to use the
shortcut, and every other user who wants to use it will have to do likewise
(so you'll have to create a shortcut on their Desktops too). Don't get too
upset, you would have to do this anyway - even if you hadn't stuffed up the
original system.mdw. This is the way Access security works.

Got all that?? <g d&r>

Regards,
Graham R Seach
Microsoft Access MVP
Sydney, Australia

Microsoft Access 2003 VBA Programmer's Reference
http://www.wiley.com/WileyCDA/WileyTitle/productCd-0764559036.html
 
R

Rick Brandt

Bob said:
After running the Security Wizard to "Secure" a single
database I have found ALL of the Access databases I try
to open LOCKED!

I'm prompted to enter a Username and Password for every
db, even db I did not protect.

The security environment is NOT controlled by which file you are opening.
This is not possible because the security environment is set up before any
file is opened. Rather it is determined by the workgroup being used at
Access startup. This is determined by a command line argument or if none
is provided your default workgroup is used.

When you created a secure workgroup to use with your protected file, Access
also made that workgroup your default (stupid decision on MS part IMO).
You need to use the workgroup administrator to change your default back to
System.mdw. Then you will not be prompted.

A good test for you secure file is to see if you can open it after you
change your default workgroup back to System.mdw. You should NOT be able
to. If you can then you applied security incorrectly and need to start
again.

If you can't get in with the default mdw then you can create a shortcut for
opening the secured mdb file that specifies your secure mdw file as a
command line argument. That way you can use the secure mdw file only when
you use the shortcut and it won't impact any of your other files. The
syntax is roughly...

"path to MSAccess.exe" "path to mdb" /wrkgrp "path to mdw"
 
J

Joan Wild

Excuse me Graham but,
It seems you took all the right actions - except one! You forgot to
create a new Workgroup file before you started.

If he didn't create a new workgroup file, and instead modified the
system.mdw then the only option is the first one you describe.
The first option (and one I know you're not going to like), is to
remove all the security you've just added, then start again (making
sure to create a new workgroup file before you start).

The second option is to make a copy of the current System.mdw file,
rename it, then fire up the secured database using it.

This would be the same as making a copy of system.mdw from the start and
securing with it. It is essential to create a new workgroup using the WA,
*not* by copying system.mdw. By creating a new workgroup file, you ensure
that the Admins Group is different.
 
G

Guest

Graham,

Is there a way to get my system back to normal WITHOUT
all of the security ?

Can I just delete the security.mdb and have the machine
and ALL of my databases back to normal ?

Like I said in my original message - I'm asked for a
Username/Password for any access database I try to open
on this machine. I just want all of this security off
everything (no more prompts for anything) and then I'll
start over.

Thank you! This is my first attempt at doing security on
 
G

Graham R Seach

Bob,

<<Is there a way to get my system back to normal WITHOUT all of the
security?>>
Sure, but you have to get rid of the security you've created.

Joan is quite correct about the Admin account (thanks for the catch, Joan),
and so my second suggestion isn't appropriate.

You'll have to manually undo all the security you created! Grant full
permissions to the Users group and the Admin user account. If you removed
the Admin user from the Admins group, put it back, and remove any Admin
password. Lastly, get rid of all other users and groups you may have
created.

Regards,
Graham R Seach
Microsoft Access MVP
Sydney, Australia

Microsoft Access 2003 VBA Programmer's Reference
http://www.wiley.com/WileyCDA/WileyTitle/productCd-0764559036.html
 

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