UtterAccess.com
X   Site Message
(Message will auto close in 2 seconds)

Welcome to UtterAccess! Please ( Login   or   Register )

Custom Search
 
   Reply to this topicStart new topic
> Login Form - Password Only, Access 2010    
 
   
redpenner
post Oct 10 2017, 03:48 PM
Post#1



Posts: 193
Joined: 16-July 10
From: Shelton, WA


I have a password-protected accdb (split) and when my users open it, they are prompted for the database password but otherwise do not log in with their username. This is serving our needs security-wise, but I'm wondering if I can create a nicer looking password prompt than the tiny box and text that comes up. Everything I find online about a login form is focused on usernames and multiple passwords - I need something with a password only. I'm assuming it would run out of an autoexec, but don't have any idea how to implement it.

Are there some instructions online somewhere that just deal with a simple 1-password login?
Go to the top of the page
 
doctor9
post Oct 10 2017, 03:59 PM
Post#2


Remembered
Posts: 18,324
Joined: 29-March 05
From: Wisconsin


redpenner,

Here's an idea:

1. Create a new unbound form, and name it "frmPassword".
2. Add a Textbox control and a label control. Name the textbox "txtPassword".
3. Set the label caption to something like "Enter Password:"
4. In the AfterUpdate event of the textbox, use code along these lines:

CODE
If Me.txtPassword = "LetMeIn" Then
    DoCmd.OpenForm "Switchboard"
    DoCmd.Close acForm, "frmPassword"
Else
    Beep
End If

"Switchboard" is the name of the form you want the users to see if they successfully enter the password.

5. Add a command button, just in case the user can't remember the password and wants to exit. For the Click event, use Application.Quit.

This is bare bones, but it sounds like that's what you want.

EDIT: I forgot to mention; make frmPassword the form that opens by default, and set it to PopUp or Modal.

Dennis
Go to the top of the page
 
redpenner
post Oct 10 2017, 04:18 PM
Post#3



Posts: 193
Joined: 16-July 10
From: Shelton, WA


Awesome! I will try that. I actually already have a switchboard form in place, so it should be pretty smooth going.

Thank you!
Go to the top of the page
 
redpenner
post Oct 10 2017, 04:59 PM
Post#4



Posts: 193
Joined: 16-July 10
From: Shelton, WA


It is coming up all right, but the "native" password prompt is still coming up first.
Go to the top of the page
 
doctor9
post Oct 11 2017, 09:22 AM
Post#5


Remembered
Posts: 18,324
Joined: 29-March 05
From: Wisconsin


redpenner,

I thought you were looking for a replacement for the database's password protection. Can you clarify what you need?

Dennis
Go to the top of the page
 
DanielPineault
post Oct 11 2017, 09:32 AM
Post#6


UtterAccess VIP
Posts: 6,135
Joined: 30-June 11



There is no way to override/customize the Database password prompt. Your only option would be to remove the password from the database and create your own security model (you can make it as simple or complex as you see fit) and use a prompt such as the one provided by Denis.
Go to the top of the page
 
redpenner
post Oct 11 2017, 10:02 AM
Post#7



Posts: 193
Joined: 16-July 10
From: Shelton, WA


Oh okay, that does answer my question. Thanks!
Go to the top of the page
 


Custom Search
RSSSearch   Top   Lo-Fi    23rd October 2018 - 08:15 PM