Discussion Locked

Access 95 trying to get value of combo b

0 helpful
5 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.
I have an App in Access 95 where I have a combo box and I want the values I select to go into the list box. I tried to do List box to list box and that worked. But I really need to have the combo box instead to do the trick.

5 replies

by camcc591

Not sure of all the details you are looking for but I created a list box with Date | Row Source Type set to Value List.

Then I made a command button with the following code in the Click Event:
If Len(List2.RowSource) > 0 Then _
List2.RowSource = List2.RowSource & ", "
List2.RowSource = List2.RowSource & Combo1.Value

This took the value of the combo box and added it to the RowSource text of the list box.

Another option would be to add the selected values from the combo box into atable. (Clear the table before you add entries.) The list box would be listing the entries of the table. In this way the selected values would be saved.

by glen_mcleod

Use the Change event:

Private Sub cboSelection_Change()
lstChoices.Add cboSelection.Text
End Sub

Glen

This discussion is closed to new replies.