If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > PC based Database Applications > Microsoft Excel > How to set up a Multi-Column Combo

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 10-04-11, 23:44
JerryDal JerryDal is offline
Registered User
 
Join Date: Jan 2002
Location: Bay Area
Posts: 473
How to set up a Multi-Column Combo

How do you set up a a multi-column combo in an Excel 2003 form. When the drop-down is clicked the two columns of data are in view. When I pick one, only the fist column appears. See attachment. Thanks.
Jerry
Attached Files
File Type: zip Multi-ColumnCombo.zip (10.1 KB, 11 views)
Reply With Quote
  #2 (permalink)  
Old 10-05-11, 15:44
JerryDal JerryDal is offline
Registered User
 
Join Date: Jan 2002
Location: Bay Area
Posts: 473
It may be that an Excel combo box can only display one field when it is collapsed. Does anyone know where that is documented, or is it just common knowledge?

I put a label over the combo box and adjusted its TOP property to line up with the combo text. The solution can be seen in the attachment.

Code:
Private Sub ComboBox1_Change()

    If Not Application.EnableEvents Then Exit Sub
    Me.Label1.Caption = Me.ComboBox1.Column(1)
    Me.cmdClose.SetFocus

End Sub
EnableEvents is disabled in the form Activate event while the combo box is being populated, then enabled when finished.

Jerry
RESOLVED
Attached Files
File Type: zip Multi-ColumnCombo.zip (11.3 KB, 5 views)

Last edited by JerryDal; 10-05-11 at 15:48.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On