"I have a form with the User ID and Password fields. What is the correct syntax to find the User_ID in the PASSWORD table that was entered in on the form and again for the PASS_WORD?"
Use a DCount() function to count the number of records that match for user name AND password, this should be either 1 (match) or 0 (no match). This has the advantage of being self-contained. . .you would put this in an OnClick event on the form:
Private Sub btnOK_Click()
If UserPasswordOK = True Then
' user validated. . .
Else
' invalid user or password. . .
EndIf
End Sub
Function UserPasswordOK() As Boolean
Dim crit As String, x As Long
If Len(Me![User ID])>0 And Len(Me![Password])>0 Then
crit = "[User ID] = '" & Me![User ID] & "' And [Password] = '" &
Me![Password] & "'"
x = DCount("*","PASSWORD",crit)
If x = 1 Then
UserPasswordOK= True
Else
UserPasswordOK = False
EndIf
Else
UserPasswordOK = False
End Function
This assumes that both user ID and password are strings.