I am trying to test for a duplicate value entered on a form and have the following code:-
When I run the form I get the 2465 error and yet the values of ID, Web_UID and Me,Web_UID can be seen in debug mode. The Dlookup is clearly working but why is it creating an error?
Code:
If IsNull(DLookup([ID], [Patient_Detail], [Web_UID] & "='" & Me.Web_UID & "'")) Then
Tester = True
Else
GoTo DupErr
End If
When I run the form I get the 2465 error and yet the values of ID, Web_UID and Me,Web_UID can be seen in debug mode. The Dlookup is clearly working but why is it creating an error?