Contolling a LostFocus event

AviationAce
AviationAce used Ask the Experts™
on
I have a form that tracks parts we have on order in our shop.  The PartNumber field has an On Lost Focus event.  That code uses the part number entered and gets it's discription from the Inventory table.

If the discription entered by the use does not match the discription in the inventory table then the user gets a message box asking if he/she wants to replace the existing discription with th eone from the inventory table.  This works fine.

The problem is I only want this check to take plase while the user is staying in the current record.  If the form is closing or is going from one record to the next, I want this check by-passed.

Thanks.
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Try moving the code to the after update event.  
AviationAceSole-Proprietor

Author

Commented:
Good idea.  I wish I had thought of it.
This way, I get some points - Thanks.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial