PC Review


Reply
Thread Tools Rate Thread

Combo box should trigger another combo box

 
 
karthik
Guest
Posts: n/a
 
      19th Oct 2008
Hi ,

Can tell me the way how could i make a combo box change according to the
selection of another combox values.

for example : if a combo box contains values such as "days of a week(ie
monday,tuesday,wednesday..... )" if one selects monday the other combo box
should display the values specified for monday(like places i need to go on
monday).

please help me out!!!
 
Reply With Quote
 
 
 
 
ShaneDevenshire
Guest
Posts: n/a
 
      19th Oct 2008
Hi,

Suppose the two combo boxes are in the spreadsheet? As a test, to
illustrate the technique: I will use the Data, Validation command to
demonstrate this idea. If you are using another combo box then let us know
whether it is a Form or Control Box control:

Range A1:A2
US
Canada

In range B1:B2
New York
San Francisco

Select B1:B2 and type US into the Name Box (the far left side of the Formula
Bar, where cell addresses appear) and press Enter. The name must be spelled
the same as you enter in A1.

In range C1:C2
Quebec
Toronto

Select C1:C2 and type Canada into the Name Box (the far left side of the
Formula Bar, where cell addresses appear) and press Enter. You must press
Enter!

Move to a cell where you will have your first a drop down list, say E1.
Choose Data, Validation, from the Allows box choose List, in the source box
enter =A1:B1 and press OK. Now you have a drop down list with two choices in
cell E1, the arrow shows when you click in the cell.

Move to the cell where you want your list to depend on the result the entry
in E1. Say H1, and choose Data, Validation, and from the Allows box choose
List, in the source box enter =INDIRECT(E1). When you click Ok you may get
an error message, ignore it.

Now test everything. Open the list in E1 and pick one of the two entries.
Move to H1 and open the drop down....

If this helps, please click the Yes button.

--
Thanks,
Shane Devenshire


"karthik" wrote:

> Hi ,
>
> Can tell me the way how could i make a combo box change according to the
> selection of another combox values.
>
> for example : if a combo box contains values such as "days of a week(ie
> monday,tuesday,wednesday..... )" if one selects monday the other combo box
> should display the values specified for monday(like places i need to go on
> monday).
>
> please help me out!!!

 
Reply With Quote
 
karthik
Guest
Posts: n/a
 
      19th Oct 2008

Hi,

Thank you for the post, it was helpful.

I have another request, suppose if the values have spaces (like instead of
"US" if its "C & C++ Programming"/ "Java Programming" and in the other combo
box if i plan to display the "Corresponding Authors" )
when i tried to name the selected field as "C & C++ Programming", it showed
an error like Special Characters not allowed.

what can i do if this is the case..???

Please Reply...


"ShaneDevenshire" wrote:

> Hi,
>
> Suppose the two combo boxes are in the spreadsheet? As a test, to
> illustrate the technique: I will use the Data, Validation command to
> demonstrate this idea. If you are using another combo box then let us know
> whether it is a Form or Control Box control:
>
> Range A1:A2
> US
> Canada
>
> In range B1:B2
> New York
> San Francisco
>
> Select B1:B2 and type US into the Name Box (the far left side of the Formula
> Bar, where cell addresses appear) and press Enter. The name must be spelled
> the same as you enter in A1.
>
> In range C1:C2
> Quebec
> Toronto
>
> Select C1:C2 and type Canada into the Name Box (the far left side of the
> Formula Bar, where cell addresses appear) and press Enter. You must press
> Enter!
>
> Move to a cell where you will have your first a drop down list, say E1.
> Choose Data, Validation, from the Allows box choose List, in the source box
> enter =A1:B1 and press OK. Now you have a drop down list with two choices in
> cell E1, the arrow shows when you click in the cell.
>
> Move to the cell where you want your list to depend on the result the entry
> in E1. Say H1, and choose Data, Validation, and from the Allows box choose
> List, in the source box enter =INDIRECT(E1). When you click Ok you may get
> an error message, ignore it.
>
> Now test everything. Open the list in E1 and pick one of the two entries.
> Move to H1 and open the drop down....
>
> If this helps, please click the Yes button.
>
> --
> Thanks,
> Shane Devenshire


 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

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 Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Make second combo column trigger event CJ Microsoft Access Form Coding 2 13th Nov 2007 09:22 PM
Combo Box Trigger for Macro using Worksheet_SelectionChange Frank Hayes Microsoft Excel Programming 2 18th Mar 2007 06:52 PM
Cannot trigger OnChange event from inspector's command bar combo box tonyl Microsoft Outlook Program Addins 0 10th Oct 2006 08:23 AM
Combo used for Find does not trigger AfterUpdate Event Pat Garard Microsoft Access 3 14th Jun 2005 06:43 AM
Combo/List Box - Trigger secondary List/Combo Box? =?Utf-8?B?RG9yZWVu?= Microsoft Access Form Coding 3 14th Oct 2004 08:05 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 04:50 PM.