Thread: Combo boxes
View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 6,953
Default Combo boxes

If you attached a file to your post,
a) that is discouraged

b) Keith won't see it since he is posting from the Microsoft Communities.

--
Regards,
Tom Ogilvy


"Graham Whitehead" wrote:

Try this

"Graham Whitehead" wrote in message
...
No problem, i will knock up a short example then you can adjust the code
as
needed - give me 5 mins.

"Keith" wrote in message
...
I understand the principle but unfortunatly I am an Access programer not
an
Excel one.

"Graham Whitehead" wrote:

Yes there is. The method I use is to have a sheet with the values that
will
be in the combo boxes. Suppose there are 4 option is combo box 1. When
the
user selects a choice from here there is an associated listindex value
with
the selection - from 0 to 3. Put the values for combo box 2 into 3
columns - lets say A,B,C & D. It is then possible to get excel to
evaluate
the length of the lists (if they are different lengths) and then create
a
loop to store these values in an array, using the listindex value as a
column selection value. Then populate the second combo box from the
values
in the array. I am assuming that you know how to code these steps - if
you
dont then I can help you with it.

"Keith" wrote in message
...
I am looking for a way to have 2 combo boxes on a worksheet, but the
values
that Appear in the second combo box depend on the value of the first
box.

Is there a way to do this in Excel?