Click to See Complete Forum and Search --> : Looking Up Data From Access


SgiGod
February 11th, 2000, 11:46 PM
I am using a Access Data Base in my program. I would like to be able to look up info from the DB
by typing a phone number in a text box and then have the rest of the info for that number show up in in the other text boxes on the form.

Thanks in Advance
Donny S.

Johnny101
February 12th, 2000, 03:28 PM
You would have to use the LostFocus or Validate event of the text box for the phone number. Then in that event you would have to pull back the information relating to that phone number and populate the screen with those values.

To get the validate event (which fires before the lost focus event) you have to set the CausesValidation property to True for that text box. FYI - The Validate event is only available in VB6.

hope this helps,
John

John Pirkey
MCSD
www.ShallowWaterSystems.com