How To: Create a multiuser login system in Microsoft Access

Create a multiuser login system in Microsoft Access

The Microsoft Office Access 2007 relational database manager enables information workers to quickly track and report information with ease thanks to its interactive design capabilities that do not require deep database knowledge. In this Microsoft Access video tutorial, you'll learn about creating a multi-user login form to password protect different areas of your database.

Here's the code:

Username.SetFocus
If Username = "staff1" And Password = "staff1" Then
MsgBox "Access Granted", vbInformation, "CD Shop"
MsgBox "Welcome", vbInformation, "CD Shop"
DoCmd.Close
DoCmd.OpenForm "F_Switchboard"
ElseIf Username = "staff2" and Password = "staff2" Then
MsgBox "Access Granted", vbinformation, "CD Shop"
MsgBox "Welcome", vbinformation, "CD Shop"
DoCmd.Close
DoCmd.OPenForm "F_Switchboard"
ElseIf Username = "manager1" and Password = "manager1" Then
MsgBox "Welcome, Manager", vbinformation, "Manager Area"
MsgBox "Please Exercise Caution When Altering Back End", vbinformation, "Manager Area"
DoCmd.Close
DoCmd.OPenForm "F_Switchboard_Manager"
Else
MsgBox "Please re-enter your Username and Password."
End If

For step-by-step instructions on implementing the above code and creating your own multiuser login system in Microsoft access, watch this how-to.

9 Comments

en guzel SOHBET siteleri

the video is not working.... just a black screen.... nothind else.

i can help with pay. contact me if u still interested!

can u give me more

I found your mulit-user login code very useful and it worked great. The code was simple and to the point. I have created a table with the users first initial and last name, the passwords can stay the same as Staff 1 and Admin 1. Do you have a video with the same code that could show how to add a DLook up code. I do not know codes at all and have googled a lot of different ones and some seem to be very lengthy. If you could help me out that would be great.

I would like to follow your videos for access. If you also have a video on how to send emails from access 2010 can you send me the link. I would greatly appreciate it.

Share Your Thoughts

  • Hot
  • Latest