How to see more columns in the diplay of a combobox

Jantje 21 Reputation points
2024-12-04T11:58:49.2966667+00:00

in an acces form I have a combobox with 5 columns of which one is the bound colomn. In the pulldown menu I see these 5 columns. if I click I only see one column item in the display. How can I see more columns? Maybe the textcolumn property should be set. But I do not know where to find it.

Access Development
Access Development
Access: A family of Microsoft relational database management systems designed for ease of use.Development: The process of researching, productizing, and refining new or existing technologies.
893 questions
0 comments No comments
{count} votes

Accepted answer
  1. Karl Donaubauer 2,056 Reputation points MVP
    2024-12-04T13:55:31.74+00:00

    Hi,

    You can't. A combobox can only show 1 column in its textbox part. Two workarounds:

    1. You could use a concateneted column (Field1 & ", " & Field2 ...) as the first visible column. You can assign it a column width of 0.01 to only see it in the textbox part, not in the list.
    2. You could show the other columns in a separate textbox next to the combobox using a textbox control source like: =YourCombobox.Column(1) & ", " & YourCombobox.Column(2) ...

    Servus
    Karl


    Access Forever News DevCon
    Access-Entwickler-Konferenz AEK

    1 person found this answer helpful.
    0 comments No comments

3 additional answers

Sort by: Most helpful
  1. Ken Sheridan 2,846 Reputation points
    2024-12-04T15:33:45.8233333+00:00

    For an example of how to display data from multiple columns in a combo box's list, by showing the values in additional unbound controls in the form you might like to take a look at DatabaseBasics.zip in my public databases folder at:

     

    https://1drv.ms/f/c/44cc60d7fea42912/EhIppP7XYMwggESpAAAAAAAB3aLXYo7DdARg01KnQIyoLg?e=fASl3m

     

    In this little demo file, the third form in the section on 'entering data via a form/subforms' is a simple Orders form in which the customer is selected in a combo box whose list includes the customer's address data.  These data are then shown in four unbound text boxes below the combo box.

     

    In the section on 'retrieving data from the database' in the same demo you'll find an example of a 'Select Contacts' combo box which shows data concatenated into a single column in the control's RowSource query.

    1 person found this answer helpful.
    0 comments No comments

  2. Jantje 21 Reputation points
    2024-12-04T20:19:15.9833333+00:00

    Karl gave me a very good suggestion. So my problem is solved

    0 comments No comments

  3. Jantje 21 Reputation points
    2024-12-04T20:20:42.2366667+00:00

    Thanks Ken, I have solved the problem with the suggestion nr 1 from Karl

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.