MrExcel Publishing
Your One Stop for Excel Tips & Solutions

List Box or Combo Box


Posted by Bieg on July 11, 2001 4:49 AM

I am trying to insert a simple combo or list box into a cell. I have several set options I want to select from a list rather than having to type them in. Another option would be to get the "pick from list" option to select from a list of preset values that are not directly above or below the cell I need it in but a list of values off to the side or on another worksheet. Any help would be appreciated.


Posted by M Walker on July 11, 2001 5:19 AM

Hi,

If its any help i've just set up a spreadsheet containing a combobox that had a list of products that could only be selected. These are on a seperate spreadsheet which i have called Totals and used the following code (thanks to Ivan).

Private Sub UserForm_Initialize()
Application.Worksheets("Totals").Activate
ComboBox1.ColumnCount = 5
ComboBox1.RowSource = "a5:a47"
End sub

This selected "Totals" when the userform was active and showed the descriptions in a5 to a47.

Hope this helps.

M Walker