Pls can someone help....
I have created a form called compliance database and I use a password form which opens the compliance form with the code below:-
Private Sub Command5_Click()
Dim strUser As String
Username.SetFocus
strUser = Username
If strUser = "user1" And Password = "user1" Then
MsgBox "Access Granted"
DoCmd.Close
DoCmd.OpenForm "Crystal Compliance Database", , , "[Service Centre / Satellite] = 'Basingstoke'", , , strUser
Else
MsgBox "Please Enter Correct Username or Password"
End If
End Sub
I have opened the crystal compliance database form and selected save as and renamed the form as belfast, so now I have two forms one compliance and the second belfast is there any way I can incorporate the second form which will only open if another pass word was inserted. how would I add it to the already existing code.
I have created a form called compliance database and I use a password form which opens the compliance form with the code below:-
Private Sub Command5_Click()
Dim strUser As String
Username.SetFocus
strUser = Username
If strUser = "user1" And Password = "user1" Then
MsgBox "Access Granted"
DoCmd.Close
DoCmd.OpenForm "Crystal Compliance Database", , , "[Service Centre / Satellite] = 'Basingstoke'", , , strUser
Else
MsgBox "Please Enter Correct Username or Password"
End If
End Sub
I have opened the crystal compliance database form and selected save as and renamed the form as belfast, so now I have two forms one compliance and the second belfast is there any way I can incorporate the second form which will only open if another pass word was inserted. how would I add it to the already existing code.