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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Set text box = selection in combo box

Status
Not open for further replies.

nunzio4

Technical User
May 12, 2003
4
GB
I am trying to set the content of a text box equal to the current selection in a combo box.

I tried inserting the following into the AfterUpdate code for the combo box, to no avail:

me("TextBoxName") = ComboBoxName

I am new to scripting, and I am have exhausted my limited ability to decipher the object browser when searching for a solution. Any pointers would be greatly appreciated.

Thank you!
Jim
 
Me!TextBoxName = Me!ComboBoxName

Should do it as you said in the After Update event of your Combo.

Bill

 
Your could also set the ControlSource property of the text box to the column of the combobox you want displayed. For example,

TextBox
ControlSource... =YourComboBox.Column(0)
 
Thank you both very much - looks like I had the syntax slightly off.

Jim
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top