Auto Populate Field 2 Based on Field 1

G

Guest

Hello,

I have a table that has two columns. One column is all numeric zip codes
and the other field is the name of the city.

What I'd like to be able to do in the form, is have our users enter the zip
code and then have the name of the city populate the "city" field. How can I
achieve this?

Thank you for your help!
 
H

Husky

Hello,

I have a table that has two columns. One column is all numeric zip codes
and the other field is the name of the city.

What I'd like to be able to do in the form, is have our users enter the zip
code and then have the name of the city populate the "city" field. How can I
achieve this?

Not all cities have their own zip code. ie: there's 4-5 or more cities inmy
area using the same zip.
Make more sense to enter a city and have the zip filled in.
 
G

Guest

Set up a table with two fields, zip codes and cities. On you main form, use a
combo box to look up zip codes with cities in the second column. (Use the
wizard option 1 I want the combo box to lookup values in a table or
query)(Include both fields inthe next option of the wizard)

Put an unbound text box on you form and set to control to
= cboYourComboName.Column(1) Note combo boxes are zero base so column 1 is
the second colum to appear (Note 2 Change the name of the combo to your combo
name)
 
G

Guest

Thanks MikeJohnB!! Worked PERFECT

MikeJohnB said:
Set up a table with two fields, zip codes and cities. On you main form, use a
combo box to look up zip codes with cities in the second column. (Use the
wizard option 1 I want the combo box to lookup values in a table or
query)(Include both fields inthe next option of the wizard)

Put an unbound text box on you form and set to control to
= cboYourComboName.Column(1) Note combo boxes are zero base so column 1 is
the second colum to appear (Note 2 Change the name of the combo to your combo
name)
 

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

Similar Threads


Top