Passing the value of a Combobox to another field.

A

Aaron

I have a combo box ("ComboLineDefault") that is looking at table
"ProductionLines" which has 2 fields (Record ID and Name" The combo box
shows the "Name" but I want to be able to pass this value to another field on
the form.

I have this code written but is passes the value of the "Record ID" not the
"Name".

lineid.Value = ComboLineDefault.Value

Thanks in Advance,
Aaron
 
M

Maurice

Aaron,

You should refer to the proper column of the combo. In this case it's column
1. The combo starts zerobased so the first value is the default being column
0.

lineid=combolinedefault.column(1)

should do the trick.

hth
 

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