check for duplicates on a form

lipin

Registered User.
Local time
Today, 18:39
Joined
May 21, 2002
Messages
149
I have a form with 2 unbound textboxes. One is date and one is Department. Also have a subform based on the department selected on the main form.
Is there a way to save the date and department in a table and if say the report has already been run for the Shipping department for a certain day then it can't be run again for that day?

So if Shipping was ran once on 11/19/03 then if a user tried to select shipping on the main form and entered 11/19/03 that I could give an error message?

I can do the error message and create a table to store the department and date info. But how would I go about checking it to see if it already exists for the same day?
 
The simplest way would be to use a Dlookup function to see if the combination of dept and date already exists in the table.
 

Users who are viewing this thread

Back
Top Bottom