No duplicate records

egyptian_prince

Registered User.
Local time
Today, 16:41
Joined
Dec 6, 2003
Messages
14
No duplicate records!!!!!!!!!!!!

I have another enquiry!

how would i make sure that the same bookings cannot be booked twice?

so for example,

Mr John Smith cannot book a trip to Liverpool twice!!!


egyptian_prince
 
egyptian,

You can set a unique index on the Table. This will work, but
you will get a "standard" Access message.

An alternative is to use the DLookup function to check if a
record exists. You can use the Form's BeforeInsert event and
bring up your own "nice" message box informing the user.

See the Help files or the Search facility here for DLookUp.

Wayne
 
Re: No duplicate records!!!!!!!!!!!!

egyptian_prince said:
so for example,

Mr John Smith cannot book a trip to Liverpool twice

Ever? Or on specific dates?
 
WayneRyan said:
You can set a unique index on the Table. This will work, but
you will get a "standard" Access message.

You can bypass this with the form's Error() event.
 
there is a problem! there is no BeforeInsert event section! im looking on design view on the form, and there's nothing of the sort! there is BeforeUpdate, and that's the closest one to it that i can find!

what would i type in anyway in the field?


egyptian_prince
 

Users who are viewing this thread

Back
Top Bottom