Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Multiple Users???

Status
Not open for further replies.

DaddyNackers

Programmer
Oct 4, 2002
16
US
Is there a way to permit multiple users within one access application over a LAN? Right now, my program only allows one user to actively use it. If another person enters the application, they have read-only rights (which makes sense because a table could be in use by the first person).

Is there a way around this?

I appreciate any and all help!!

Thanks much,
Mike
 
Check you options. Goto TOOLS | OPTIONS. Then select the tab entitled "Advanced". Then check the item "Shared" under "Default Open Mode", then check "Edited Record" under "Default Record Locking".
 
Thanks for this information. I got the "READ ACCESS ONLY" message to dissappear.

How do I find who is logged into the database? When a two people are running the same query, the second person gets an error message saying...

"Couldn't lock table 'TABLE'; currently in use by user 'Admin' on machin '12345'."

Is there a way to tell the second person the actual user's name, instead of 'Admin'?

Thanks,
Mike
 
Admin is the name of the user. That is, when your user opens your database, by default, he/she becomes user Admin. Your users will need to log into your Access database for their name to appear. The easiest way to do this is to assign user Admin a password. Then, via the Security menu item, add new users.
 
But if you're doing what FancyPrarie suggests, don't let yourself think you're "securing" your database. There are plenty of ways to get into a fully secured Access database, but _just_ adding an admin pwd and user accounts will make it _really_ easy for anyone to get into that database.

On the other hand, it doesn't sound like you're looking for security here, just to be able to id the users, and her (I think I remember that FP is a woman from another thread. Sorry if I'm wrong) solution will work quite well for that.

Jeremy =============
Jeremy Wallace
Designing, Developing, and Deploying Access Databases Since 1995

Take a look at the Developer's section of the site for some helpful fundamentals.


Remember to reward helpful tips with the stars they deserve.
 
I set up myself as the admin, and another employee for testing. It works well on my computer. When I had the other employee log onto the database, he wasn't prompted for the password, and was automatically called the admin. I also have a password for the admin, so at least he should have been prompted for a password when opening the database.

Do you know what I am doing wrong now?

I really appreciate all your help!

Thanks,
Mike
 
First off, JeremyNYC is WRONG. I'm not a woman. JeremyNYC, I thought about the security thing too, but assumed DaddyNackers didn't want to go there.

Now, as far as the other user not getting a login prompt: it's because you are not sharing the same workgroup file (.mdw). By default, Access uses the workgroup file System.mdw. And, since you are both running Access on different machines, you're each opening up your own copy of System.mdw. You need to create a workgroup and copy the workgroup file to your user's machine.

HOWEVER, the best way to do this is to use the Security wizard (as JeremyNYC alludes to). Create a new workgroup and put it on a server. Then copy your secured database to your user's machine. Then setup a shortcut to the database and add this to the target property of the shortcut:

path\msaccess.exe \path\yourdatabase.mdb /wrkgrp \path\yourworkgroup

There are plenty of articles in tek-tips on how to do aoo of this.
 
FancyPrarie,

I DO appologize. I'm not sure why I remembered that from a previous post, though I'm sure I won't get it wrong again!

Jeremy =============
Jeremy Wallace
Designing, Developing, and Deploying Access Databases Since 1995

Take a look at the Developer's section of the site for some helpful fundamentals.


Remember to reward helpful tips with the stars they deserve.
 
I am not using this for security reasons. I simply want to have a message telling a user the name and phone number of the person currently using the tables (if two people were trying to access the same query).

Your help so far is really benifitting me.

One more question: How do I limit the newly created workgroup to my application only. It seems that any MS Access database I now open, prompts for the id's and passwords I just set up. Is there a way around this?

Thanks,
 
DN,

Check out the Database Deployment article on my website, in the Developers' section for a long and involved way to do this. I've found this method to be very helpful.

The quicker way to do it, though, is to make a shortcut to your database and alter the "target" property of the file so that it looks something like this:
"path/MsAccess.exe" "Path/YourDatabase.mdb" /wrkgrp "Path/Your.mdw"

And make sure that your users are members of the default workgroup, not your workgroup.

Jeremy =============
Jeremy Wallace
Designing, Developing, and Deploying Access Databases Since 1995

Take a look at the Developer's section of the site for some helpful fundamentals.


Remember to reward helpful tips with the stars they deserve.
 
I did your shortcut suggestion. But, I am still unable to limit this workgroup to only one application. How do I....

"...make sure that your users are members of the default workgroup, not your workgroup." - I think this is my problem.

Thanks,
Mike
 
I discovered how to have one application point to one workgroup (Thanks for all your help - much appreciated). One other missing piece of information I need is, how to find who is currently using the application. I want to be able to show a message box telling the user "Joe Black is currently using this table. You can reach him at 867-5309!" I want this message to be shown insead of the generic error message.

How do I do this????

Thanks much,
Mike
 
Mike,

I've never done this, but I would think that you would have to make a table that records who logs in and who logs out and make queries based on that. One problem here is that if a person hits the power button on the computer wehn the app is running it will look like they are still logged on. You can write code that clears that record the next time that person logs on, but that doesn't quite do the trick. This leaves you with writing code that uses the ontimer event, to update this table every five minutes. Then when you do your query you only show users who have updated their recrod within the last ten minutes.

Of course, all of this is just off the top of my head, and I'm sure thee are some good programmers who have instituted things like this and know the ins and outs of the process.

Jeremy =============
Jeremy Wallace
Designing, Developing, and Deploying Access Databases Since 1995

Take a look at the Developer's section of the site for some helpful fundamentals.


Remember to reward helpful tips with the stars they deserve.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top