What am I doing wrong here?
I am trying to create a data lookup that will return the county when I enter the zip code.
I have a table with information on our clients, names and addresses and phone numbers) and a table that contains every zip code in the state and the counties that the zip code is in.
The form is based off of the Clients table. I have made a combo box named zip code. Using the wizard I selected the Zip Code and Counties fields from the Zip Code Table. I selected that I would like the data stored in the Zip Code filed of the Clients table.
I then created an unbound text box called County on the form.
I placed the following code in the AfterUpdate property of the Zip Code combobox:
Me.County = ComboBox.Column(1)
Now I thought this should fill in the County Data automatically, however when I update the zip code I receive a run time error and when I select debug I am returned taken to this line of code.
What is going wrong?
Also, can I select the County field on the Control Source of the County text box so that the County is stored in that field in the Clients table?
I am trying to create a data lookup that will return the county when I enter the zip code.
I have a table with information on our clients, names and addresses and phone numbers) and a table that contains every zip code in the state and the counties that the zip code is in.
The form is based off of the Clients table. I have made a combo box named zip code. Using the wizard I selected the Zip Code and Counties fields from the Zip Code Table. I selected that I would like the data stored in the Zip Code filed of the Clients table.
I then created an unbound text box called County on the form.
I placed the following code in the AfterUpdate property of the Zip Code combobox:
Me.County = ComboBox.Column(1)
Now I thought this should fill in the County Data automatically, however when I update the zip code I receive a run time error and when I select debug I am returned taken to this line of code.
What is going wrong?
Also, can I select the County field on the Control Source of the County text box so that the County is stored in that field in the Clients table?