Auto Populate Field

G

Guest

I have a form in which I would like to auto populate second field based on
item chosen on first combo drop down list.

For example, field A is called Fruits and Field B is called Description. If
I pick Apple from field A drop down list, Description portion of field B
should be auto-matically populated based on selection of field A.

Most likely this would be "On Lost Focus" event but not sure about the code.
Any help would be appreciated.

Thanks,
Deven
 
G

Guest

In the text box,where the name should apear, you can refer to second column
of the combo

In the text box ControlSource property you can write

=[ComboBoxControlName].column(1)

The column number start with 0
 
A

Al Campagna

Deven,
Make the combo (ex. cboFruit) a 2 column combo (Fruit/Description and ColumnCount = 2)
Create an unbound calculated text control on the form with a ControlSource of...
= cboFruit.Column(1)
(Combo columns are numbered 0,1,2,3,... etc..)
After Fruit is selected, the Description will "display" in the text control.
--
hth
Al Campagna . Candia Computer Consulting . Candia, NH USA
Microsoft Access MVP
http://home.comcast.net/~cccsolutions

"Find a job that you love, and you'll never work a day in your life."
 
G

Guest

Thank you both for quick response. I will try this tomorrow and let you guys
know.

Thanks,
Deven

Ofer Cohen said:
In the text box,where the name should apear, you can refer to second column
of the combo

In the text box ControlSource property you can write

=[ComboBoxControlName].column(1)

The column number start with 0

--
Good Luck
BS"D


Deven said:
I have a form in which I would like to auto populate second field based on
item chosen on first combo drop down list.

For example, field A is called Fruits and Field B is called Description. If
I pick Apple from field A drop down list, Description portion of field B
should be auto-matically populated based on selection of field A.

Most likely this would be "On Lost Focus" event but not sure about the code.
Any help would be appreciated.

Thanks,
Deven
 

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

Top