Hey,im sorry to turn this around but i have a simple question.Im currently working on a login form.ive got the code i want to validate the id,email adress and password of a user using DLookup.but the trouble is ,after it validates it adds the entered data into the table! so in the end I have 2 of the same records in the database.Is this a common problem?here is my code.Its pretty simple.
Private Sub cmd1_Click()
If (DLookup("Password", "table1", _
"[ID]=" & Me.txtid.Value)) > 0 Then
'Close logon form and open splash screen
DoCmd.Close acForm, "f1"
DoCmd.OpenForm "f2"
Else
MsgBox "Password Invalid. Please Try Again", vbOKOnly, _
"Invalid Entry!"
Me.Password.SetFocus
End If
End Sub
Private Sub cmd1_Click()
If (DLookup("Password", "table1", _
"[ID]=" & Me.txtid.Value)) > 0 Then
'Close logon form and open splash screen
DoCmd.Close acForm, "f1"
DoCmd.OpenForm "f2"
Else
MsgBox "Password Invalid. Please Try Again", vbOKOnly, _
"Invalid Entry!"
Me.Password.SetFocus
End If
End Sub