We help IT Professionals succeed at work.

Not allow data entry in a new record if situation already exists.

SteveL13
SteveL13 asked
on
69 Views
Last Modified: 2018-10-24
I have 3 text fields on a form.  They are txtCode, txtLastName, and txtCombined.  txtCombined puts the 1st two fields together.  So, for example, if I enter "1234" (is a text field),  in the first field and "Johnson" in the 2nd field then txtCombined displays 1234Johnson.

But if I have already entered that combination in a previous record I want to display a message to the user letting them know that combination already exists and undo the two field entries so the user can try again.

I've tried all kinds of beforeupdate and afterupdate events and oncurrent events but nothing is working.  Thoughts?
Comment
Watch Question

CERTIFIED EXPERT
Most Valuable Expert 2015
Distinguished Expert 2018
Commented:
This one is on us!
(Get your first solution completely free - no credit card required)
UNLOCK SOLUTION

Author

Commented:
I assume you mean the beforeupdate event of the form, correct?
CERTIFIED EXPERT
Most Valuable Expert 2015
Distinguished Expert 2018

Commented:
Yes.
CERTIFIED EXPERT
Distinguished Expert 2017
Commented:
This one is on us!
(Get your first solution completely free - no credit card required)
UNLOCK SOLUTION
Unlock the solution to this question.
Join our community and discover your potential

Experts Exchange is the only place where you can interact directly with leading experts in the technology field. Become a member today and access the collective knowledge of thousands of technology experts.

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.