[b]How do you link 2 drop-down menus?[/b]

jd1655

New Member
Joined
Nov 2, 2005
Messages
2
Hello,

I'm in a lurch... I need to link to side-by-side drop down menus. It goes like this:

*First column has a DD menu with a list of COUNTRIES
*Second column has a DD menu with list of NUMBERS (only 2 numbers). Certain NUMBERS in column two go with certain COUNTIRIES from the first column (USA gets 1, France 2, Mexico 1, Germany 2 etc...)
*As it stands, the user must first choose the COUNTRY in column 1, and then choose the corresponding NUMBER that GOES this that country in column two. (note: There two separate columns must remain)

**I want to make it so that when the COUNTRY is selected in column one, the corresponding NUMBER automatically appears in column 2

Can anyone help? I've got a deadline fast approaching!!

Best regards,

Jeff :wink:
 

Excel Facts

Wildcard in VLOOKUP
Use =VLOOKUP("Apple*" to find apple, Apple, or applesauce
Use VLOOKUP.

For example, if the dropdown list is in A1 and you want to return the number in B1:
Book1
ABCDE
1France2USA1
2France2
3Mexico1
4Germany2
Sheet1
 
Upvote 0
Hi Kristy,

Thanks for your quick response. However, I don’t share your level of knowledge with Excel and I didn’t understand what I need to do.

To expand, the two columns I mentioned before are in a group on 30 columns. The first column I mentioned has cells with drop down menus containing a selection of about 200 countries. The second column’s cells have drop down menus with two numbers (1 & 2).

About a third of the countries in column one will require the #1, the rest will require the number 2.

If you have a moment, could you expand on your previous response? I am not to knowledgeable of formulas and the like.

Thanks again,

Jeff
 
Upvote 0
I can try :) Ok. Using the cell references in the example I posted above:

Columns C and D contain a list of all of the countries and their associated numbers.

Cell A1 contains the dropdown list of countries.

Cell B1 contains this formula:
=IF($A1="","",VLOOKUP($A1,$D$1:$E$4,2,0))

What this formula does is looks for the word in cell A1 within column D. If it finds an exact match, it will then look at the second column of the table (column E, in this case) and return the number for that word.

So if you select France in A1, and it is listed in the table, it will automatically return "2" in cell B1. If you select Mexico, it will display "1" and so on.

Edit: Here, I made a larger example:
Book1
ABCDEF
1Select country from list...Number appears hereList of countries and assoc. numbers
2Canada1Canada1
3Germany2England1
4Scotland1France2
5Portugal2Germany2
6United States1Mexico1
7England1Portugal2
8Mexico1Scotland1
9Spain2Spain2
10France2United States1
Sheet1
 
Upvote 0

Forum statistics

Threads
1,222,405
Messages
6,165,867
Members
451,989
Latest member
DannyBoy1977

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top