matching an entry to a lookup

  • Thread starter Thread starter josh
  • Start date Start date
J

josh

i have a field where a user enters his unique user id,
which is a 7 digit code. How can i have that code
rejected if it does not match the code from another
table. Lets say i have a record with the following
information name: john smith user id: 1234567 ... in this
form i want the following 2 fields user id and comments.
if the user enters 1234567 and a comment it will be
accepted but if he enters a user id that does not match
one on record it will be rejected. so fai i have only
been able to acheive this by setting the user id field on
the form to limit to list but this shows all of the user
id in a list and i would not want this list to be shown.
in other words i need a field where the user enters his
code which cannot be selected from a list and must match
a user id in his personal file

any help would be greatly appreciated
 
use the DCount function to count how many times the user
ID that was entered is in the table. If the count is more
than one, it must match, if not, it should be rejected.
Check the help file regarding DCount
 
Back
Top