Buckar00B0nzai
Technical User
I have a form that tracks project status, and the individuals who use the form are not supposed to move from phsae 1 to phase 2 (all the way through phase 5) without approval from management. I have a checkbox for each phase (I-V) listed on the bottom of the form, and would like these to be password protected (for management only). If someone checks (or "un-checks) the box and enters the correct password, the check (or "un-check") should stay. If they enter the incorrect password, I would like their Check (or "un-check") to be reversed to the original setting. I am a novice and am wondering if anyone can help. Here is the code that I have so far in the "On Click" event for the checkbox named "Phase I".
Private Sub CtlPhase_I_Click()
If InputBox("Enter Password to Delete Record") <> "Password" Then
Exit Sub
Else
GoTo Err_CtlPhase_I_Click
End If
On Error GoTo Err_CtlPhase_I_Click
Exit_CtlPhase_I_Click:
Exit Sub
Err_CtlPhase_I_Click:
If Me.CtlPhase_I.Value = -1 Then
Me.CtlPhase_I.Value = 0
Else
Me.CtlPhase_I.Value = -1
End If
End Sub
Please help.
Thanks in advance.
Private Sub CtlPhase_I_Click()
If InputBox("Enter Password to Delete Record") <> "Password" Then
Exit Sub
Else
GoTo Err_CtlPhase_I_Click
End If
On Error GoTo Err_CtlPhase_I_Click
Exit_CtlPhase_I_Click:
Exit Sub
Err_CtlPhase_I_Click:
If Me.CtlPhase_I.Value = -1 Then
Me.CtlPhase_I.Value = 0
Else
Me.CtlPhase_I.Value = -1
End If
End Sub
Please help.
Thanks in advance.