After Update Code

J

JK

I have a form to enter in new projects. Currently when someone enters in a
new project they must fill in all the required information in order to save
the record and then at that point the system will tell them if that project
is already entered or not. Is there some code that I can put in the
afterupdate field that will check for this once the person attempts to move
into the next box?
 
C

Chegu Tom

It is probably better in the before update event. That way you can cancel
the update if


if dcount( the paramenters to count the number of records with that key
field)>0 then
msgbox "You already have that project number"
cancel=true
endif
 
J

JK

I actually have such a combo box but the users don't always use it. They
prefer to just enter things in new
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top