Hi all, back again ! I have had to put my DB on hold while working on another project.
Just trying to finish things off now.
I couldn't really find the right words to describe what I want in the title !
So.. what I have is a password entry popup, it's very simple and there is only one password, so it's coded into the form.
There is an unbound text box for the password, set with the password input mask.
An OK button and an Exit button.
The OK button has this code on the 'On Click'
Now what I want it to do is automatically move to the OK button when the correct password is entered, so that you can just hit Enter.
Currently you either have to press the OK button with your mouse, or hit Enter to move to the OK button and then press Enter again to activate it.
Sounds a bit fussy but I just want it to at least seem a bit more professional
Any help highly appreciated.
D.
Just trying to finish things off now.
I couldn't really find the right words to describe what I want in the title !
So.. what I have is a password entry popup, it's very simple and there is only one password, so it's coded into the form.
There is an unbound text box for the password, set with the password input mask.
An OK button and an Exit button.
The OK button has this code on the 'On Click'
Code:
Private Sub cmdOK_Click()
If IsNull(passwordentry) Then
passwordentry = "*"
End If
Dim PW As String
PW = "whatever"
If PW <> passwordentry Then
MsgBox "Wrong Password", vbCritical, ""
Me.passwordentry.Value = ""
Me.passwordentry.SetFocus
Else
DoCmd.Close acForm, "PasswordEntry"
DoCmd.OpenForm "MainMenuForm"
End If
End Sub
Now what I want it to do is automatically move to the OK button when the correct password is entered, so that you can just hit Enter.
Currently you either have to press the OK button with your mouse, or hit Enter to move to the OK button and then press Enter again to activate it.
Sounds a bit fussy but I just want it to at least seem a bit more professional
Any help highly appreciated.
D.