Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Limit Number of Users in Microsoft Access

Posted on 2007-12-06
10
Medium Priority
?
1,135 Views
Last Modified: 2008-02-05
I have a Microsoft Access front end connected to a Microsoft Accss backend. The back end is on a netowkr share. I would like to be able to limit the number of users that can connect to the back end to a certain number. How can I limit the number of users to my backend database?
0
Comment
Question by:AccessYourBiz_Com
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
10 Comments
 
LVL 20

Expert Comment

by:clarkscott
ID: 20422185
There's an Access Locking file is created when ever a user accesses an mdb.  It's called 'YourMDBName".ldb

If you open this ldb file using NotePad, the entries look like this.
XFG8J541                        Admin    

This shows a single user.  If more users, this will duplicate (not wrap around) for all users.
You could write a function that opens this file to read and string-input and dissect to determine number of users.

Scott C
0
 
LVL 75
ID: 20422200
There is no inherent way to do this.  However, you might be able to accomplish this using Tony's app launcher ... since each user opens the FE via this program ... and you may be able to keep track of how many users are in the back end.

http://www.granite.ab.ca/access/autofe.htm

Of course, you could devise some scheme looking at the LDB file and counting the number of active users - but you would still need a common entry point to lock out a user after the max had been reached.

Why do you want to do this?

mx
0
 
LVL 75
ID: 20422208
"You could write a function that opens this file to read and string-input and dissect to determine number of users."

But ... how would you keep the 'next' user from opening the frontend ?

mx
0
NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

 
LVL 75
ID: 20422382
Interesting link Tony.

mx
0
 
LVL 8

Accepted Solution

by:
dds110 earned 1500 total points
ID: 20423507
create a new table to hold a count of users.  When the front-end is opened (assuming a form is opened) check the count and add 1 to it.  If the count is met, notify the user and then shut down that specific front end.  When the form is closed, decrement the count in the table by 1.

HTH

dds
0
 
LVL 3

Author Comment

by:AccessYourBiz_Com
ID: 20457439
I found this link to Microsoft about using a dll that is provided in this utility.
http://support.microsoft.com/kb/176670

I tried the example code and everthing seemed to work OK except when users were logging off. I limited the users to 3 and when all three users connected it would not let a fourth on. When I had one or two of the users log off I still was not able to connect even though there was only one user connected. I found that all the users had to disconnect from the back end in order for the ldb to clear out all the user information. Does anyone have any experiencing using this dll?
Thanks Again!!!
0
 
LVL 8

Expert Comment

by:dds110
ID: 20460819
The LDB, once opened, will always contain data for each user that has interacted with the database until all users have logged out.  In other words, if Joe logs in and then logs out while Sally is logged in, the LDB file will still contain entries for both Joe and Sally.  AFAIK, the LDB does not refresh.

Maybe someone can prove me wrong.
0
 
LVL 75
ID: 20460885
dds110

You are correct. The LDB will showed user who have logged in and then out as 'Suspect' = Yes and 'Logged On' = No.  whereas users currently logged in are the opposite.  Once the last person logs out, the LDB is cleared ... well, because it is deleted.

In your example I am Suspect because my name IS Joe :-)

mx
0
 
LVL 8

Expert Comment

by:dds110
ID: 20464649
So the LDB does refresh.  I learn something new everyday.
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

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

This article describes two methods for creating a combo box that can be used to add new items to the row source -- one for simple lookup tables, and one for a more complex row source where the new item needs data for several fields.
Instead of error trapping or hard-coding for non-updateable fields when using QODBC, let VBA automatically disable them when forms open. This way, users can view but not change the data. Part 1 explained how to use schema tables to do this. Part 2 h…
Learn how to number pages in an Access report over each group. Activate two pass printing by referencing the pages property: Add code to the Page Footers OnFormat event to capture the pages as there occur for each group. Use the pages property to …
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…

604 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