Hi
It will not work reliably in a multi-user environment, my comments had nothing to do with autonumbers
Consider this:
User A input their "unique Number" (say 10), and tabs off the control, the after update event fires and the number is checked for uniqueness, all OK at this point, but remember the record has not at this point been written to the recordset
User A is interupted by a telephone call, during this interuption..
User B inputs the "unique number" (say 10), and tabs off the control, it will again be regarded as OK, since at this point User A's record has not been comitted
User B saves their record
User A finishes telephone call and commits their record bang we have a duplicate record
It will be necessary to have error trapping code in the onerrro event of the form to trap this error and request the user to eneter a new number
D
Regards
Ken Reay
Freelance Solutions Developer
Boldon Information Systems Ltd
Website needs upgrading, but for now -
UK