Link to home
Start Free TrialLog in
Avatar of Rick Danger
Rick DangerFlag for United Kingdom of Great Britain and Northern Ireland

asked on

Access97 Workgroup problems

I have a customer running an Access97 database that now needs some changes. He has sent me a copy of the database but when I open it I get permissions issues. I therefore I asked him to send me the workgroup file but I still cannot open it. Is there a way around this? When I go to his office I can open it, because it asks for username and password, which I input and it opens.
He also has Access 2007, so if he converted the db to that version would these issues go away? Or is there another way?
Avatar of Armen Stein - Microsoft Access MVP since 2006
Armen Stein - Microsoft Access MVP since 2006
Flag of United States of America image

You need to build a shortcut that specifies MDW file when the app opens.  Look at the command line switches, specifically the /WRKGRP option.
He also has Access 2007, so if he converted the db to that version would these issues go away? Or is there another way?
Converting to .accdb would remove User Level Security, but that could open up a whole new can of worms. Best to follow Armen's advice and use the wrkgrp switch to open the file.
Avatar of Rick Danger

ASKER

I have the shortcut - complete_path_to_access\msaccess.exe complete_path_to_mdb\mdbName /wrkgrp complete_path_to_mdw\Security.mdw

Does this mean that if I set my own workgroup up I then refer to it in this shortcut, and therefore when I open the database it will use my new workgroup instead of the one they have?
The shortcut tells Access to open the database using the workgroup specified in by the /wrkgrp command.

If ULS is setup correctly in that database, you are required to use the correct workgroup to open the database. So if I secure the database using MyWorkgroup.mdw and you try to open it with YourWorkgroup.mdw, you should not be able to do so and should get the "You don't have permissions blah blah .." prompt.

If the database is no secured correctly (which happens a LOT) then you can use any workgroup file to open the database, including the default system.mdw. If you use the incorrect file, you may or may not have troubles working with objects in the file, depending on exactly what was done in regard to security.
sorry for the delay in getting back to you.

I've had no luck with this. Using the WRKGADM.EXE tool I was able to create a new workgroup. I then used the shortcut as above, but still no luck.

Any clues on how to get round this?
You cannot simply create a workgroup file and use that to open the database. You must use the CORRECT workgroup file to open the database. If you don't have that workgroup file, and if the database is correctly secured, then you cannot get into the database.

Your shortcut syntax is correct, but I've had issues when trying to open secured databases with newer versions of Access. In some cases, I've had to include the User and Pwd switches, so my final shortcut Target looked like:

"full path to msaccess.exe" "full path to database" /wrkgrp "full path to workgroup" /user UserName /pwd Password

If that does not work, then find out how your customer opens the database on their machine. If they don't use a shortcut, then you'll need to examine which workgroup file is used on that machine, and get a copy of that workgroup file.
LSM
I've done that. I've even opened it on their machine. I've taken a copy of the database and their workgroup files. However, I have just thought - how do I know which Workgroup file they are using for a particular database?
They are either pointing to it with the shortcut using the /WRKGRP command line switch (recommended), or they are joined to the workgroup using the workgroup administrator tool (not best practice).

If the former, you'd see it in the shortcut.

If the latter, you need to open the workgroup administrator on their PC and see which workgroup they are currently joined to.  They would also see the side effect that *every* database they open prompts them for a password, not just their particular app.  (That's why this method isn't recommended.)
However, I have just thought - how do I know which Workgroup file they are using for a particular database?
You really cannot know this easily by examining the database only. The simplest way to determine the machine's default workgroup is as Armen suggests - use the Workgroup Administrator on that machine.

If they are using a shortcut to open the database, and if the database is secured, then you can examine the shortcut's Target.

If none of those reveal any information, then it's possible they simply modified the default system.mdw file (which is the same across all installations of Access), but then you'd be able to open the db with YOUR copy of system.mdw.

So the questions are:

1) How are you trying to open the database on YOUR machine? If you're doing it through a shortcut, then post the FULL syntax of that shortcut (copy/paste it here).

2) Exactly what "permissions issue" are you getting? Can you post a screenshot of the message you're getting?

3) What version of Access are YOU using on your machine?
"... it's possible they simply modified the default system.mdw file"

Thanks LSM.  That's such a bad practice, I forgot about it!  :)  Good catch.

"...but then you'd be able to open the db with YOUR copy of system.mdw"

Well, if it isn't prompting for a password, then Admin still has no password and is defaulting.  And Admin may have no permissions to the app.  This would be easily tested by making a copy of the system.mdw, adding a password for Admin, then using it to try to open the app.  But there *still* may be a problem if the user's system.mdw file has different users and groups set up.

If the user's system.mdw file has been modified, the best bet is to bring over a copy of it and use it to open the app.  If that works, then it can be copied to a new name (e.g. MyApp.mdw) and specified in the shortcut.

Cheers,
Armen
thanks for the help offered. I have been supplied a solution to this, but not been given the method on how to do it. I am therefore going to close this question, but am not able to supply the solution.
ASKER CERTIFIED SOLUTION
Avatar of Rick Danger
Rick Danger
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I have found the solution by asking somebody outside of EE. I don't know the method used.