johnwiseman
MIS
Hi.
I am using the following code to disable the Shift Key on Start Up. Unfortunately when I type in the password the words are visable. I need the words to appear ******** like you can on Tables.
Here is the code. Thanks in advance for any help.
Private Sub bDisableBypassKey_Click()
On Error GoTo Err_bDisableBypassKey_Click
Dim strInput As String
Dim strMsg As String
Beep
strMsg = "This Database Is Locked" & vbCrLf & vbLf & _
"To Unlock Enter the Password."
strInput = InputBox(prompt:=strMsg, title:="Disable Bypass Key Password")
If strInput = "THEPASSWORD" Then
SetProperties "AllowBypassKey", dbBoolean, True
Beep
MsgBox "The Bypass Key has been enabled." & vbCrLf & vbLf & _
"The Shift key will allow the users to bypass the startup options the next time the database is opened.", _
vbInformation, "Set Startup Properties"
Else
Beep
SetProperties "AllowBypassKey", dbBoolean, False
MsgBox "Incorrect ''AllowBypassKey'' Password!" & vbCrLf & vbLf & _
"The Bypass Key was disabled." & vbCrLf & vbLf & _
"The Database is Locked"_
vbCritical, "Invalid Password"
Exit Sub
End If
Exit_bDisableBypassKey_Click:
Exit Sub
Err_bDisableBypassKey_Click:
MsgBox "bDisableBypassKey_Click", Err.Number, Err.Description
Resume Exit_bDisableBypassKey_Click
End Sub
I am using the following code to disable the Shift Key on Start Up. Unfortunately when I type in the password the words are visable. I need the words to appear ******** like you can on Tables.
Here is the code. Thanks in advance for any help.
Private Sub bDisableBypassKey_Click()
On Error GoTo Err_bDisableBypassKey_Click
Dim strInput As String
Dim strMsg As String
Beep
strMsg = "This Database Is Locked" & vbCrLf & vbLf & _
"To Unlock Enter the Password."
strInput = InputBox(prompt:=strMsg, title:="Disable Bypass Key Password")
If strInput = "THEPASSWORD" Then
SetProperties "AllowBypassKey", dbBoolean, True
Beep
MsgBox "The Bypass Key has been enabled." & vbCrLf & vbLf & _
"The Shift key will allow the users to bypass the startup options the next time the database is opened.", _
vbInformation, "Set Startup Properties"
Else
Beep
SetProperties "AllowBypassKey", dbBoolean, False
MsgBox "Incorrect ''AllowBypassKey'' Password!" & vbCrLf & vbLf & _
"The Bypass Key was disabled." & vbCrLf & vbLf & _
"The Database is Locked"_
vbCritical, "Invalid Password"
Exit Sub
End If
Exit_bDisableBypassKey_Click:
Exit Sub
Err_bDisableBypassKey_Click:
MsgBox "bDisableBypassKey_Click", Err.Number, Err.Description
Resume Exit_bDisableBypassKey_Click
End Sub