Hello, i am currently creating a database for inspection so logging parts, there is multiple areas that i want only certain people to access for example, the operator can submit the part to be checked without password, but when the inspector completes his form i need it to be password protected, i have the password working fine however i want the inspectors name to get automatically submitted on the following form in a Form field when the password is inputted. i will include below my password VBA code any help would be greatly appreciated. many thanks in advance.
Dale
Private Sub Command102_Click()
'Attached to On Click Event of Command15
Dim strpasswd
strpasswd = InputBox("Enter Password", "Restricted From")
'Check to see if there is any entry made to input box, or if
'Cancel button is pressed. if no entry made then exit sub.
If strpasswd = "" Or strpasswd = Empty Then
MsgBox "No Input Provided", vbInformation, "required Data"
Exit Sub
End If
'If correct password is entered open Editor page
'If incorrect password entered give message and exit sub
'Password Log
'Setter33725 = DJ
'Trebor1961 = RD
If strpasswd = "Setter33725" Or strpasswd = "Trebor1961" Then
DoCmd.OpenForm "Supervisor Sign Off", acNormal
DoCmd.Close acForm, "Main Menu", acSaveYes
Else
MsgBox "sorry, you do not have access to this form (If you have forgotten your password please see D.Jolliffe/R.Topp)", vbOKOnly, "Important Information"
Exit Sub
End If

Private Sub Command102_Click()
'Attached to On Click Event of Command15
Dim strpasswd
strpasswd = InputBox("Enter Password", "Restricted From")
'Check to see if there is any entry made to input box, or if
'Cancel button is pressed. if no entry made then exit sub.
If strpasswd = "" Or strpasswd = Empty Then
MsgBox "No Input Provided", vbInformation, "required Data"
Exit Sub
End If
'If correct password is entered open Editor page
'If incorrect password entered give message and exit sub
'Password Log
'Setter33725 = DJ
'Trebor1961 = RD
If strpasswd = "Setter33725" Or strpasswd = "Trebor1961" Then
DoCmd.OpenForm "Supervisor Sign Off", acNormal
DoCmd.Close acForm, "Main Menu", acSaveYes
Else
MsgBox "sorry, you do not have access to this form (If you have forgotten your password please see D.Jolliffe/R.Topp)", vbOKOnly, "Important Information"
Exit Sub
End If