Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ComboBx/3Field Values to Variables/One Click?

Status
Not open for further replies.

JimCowan

Technical User
Jul 12, 2000
10
CA
I want to put 3 field values from a ComboBx into 3 variables by one click on the combo list by changing the BoundColumn property.
Here is my code:

Combo138.BoundColumn = 2
Var2 = Combo138.Value
Debug.Print "Var2=" & Var2

Combo138.BoundColumn = 3
Var3 = Combo138.Value
Debug.Print " Var3=" & Var3

Combo138.BoundColumn = 4
Var4 = Combo138.Value
Debug.Print " Var4=" & Var4

What happens is that at the end of the code, all 3 variables get the same value ie the last value.

Also, the value is often the wrong value.
How do I update the value after each line of code executes?
Any help is appreciated.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top