multiple item select from a combo box

J

jonefer

I want to use this as a navigational tool, rather than to "input" values into
a database.

This control will be on a form that sets parameters for graphical chart
displays.
One of the requirements is to be able to select multiple values from a 2nd
combo box after a 'parent' 1st combo box determines what should be in the 2nd
one.

I have a couple of ideas of how to do this, but was just wondering if
someone has already tackled something like this before.

I suppose I could populate a temporary table that has yes/no values in it
and display that in a subform (which scrolls) and have a button beside the
subform. But short of trying that immediately, I wouldn't mind any other
suggestions.

Oh, also I am planning to create a formula that creates the string "a, d,
f" to be used as my parameter after the multiple items are selected.
 
D

Damon Heron

Why not have your second combobox a listbox instead? Then you could set the
listbox property to multiselect. The rowsource of the listbox would be a
sql string based on the selection in the first combobox. See listbox
Selected property in vbHelp for an example.


Damon
 
J

jonefer

I need for the control to take up the small footprint of the combo box and to
be able to scroll also, can this be done?

That's why I thought of a subform which you can squish down to the size of
one textbox (except for 1/4" on the right side).
 
J

jonefer

Ok I'm using a listbox which I've set the multi-select property to
'Extended'. The dilemma I am having is that when I click the scroll bar, it
changes the selection. For example if I select A and B and then I click the
scroll bar to try to select other values, my A and B selection becomes
UNSELECTED and only C becomes selected.
 
D

Damon Heron

Read the vb help on listboxes multiselect -Extended requires you to hold
down the Shift key to make multiple selections. Simple selects or unselects
by simply clicking the mouse on the selections you want. You may want to
temporarily make your listbox larger until you are familiar with how it
works.

Damon
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top