Calling up a dropdown based on the value of a cell

SandsB

Well-known Member
Joined
Feb 13, 2007
Messages
616
User enters a value to cell A1.
Cell A2 becomes a drop down based on a named range. So if you enter "Mom" in A1 you get one drop down list in A2, if you enter "Dad" in A1 you get a different drop down list.
Possible?
 

Some videos you may like

Excel Facts

How to calculate loan payments in Excel?
Use the PMT function: =PMT(5%/12,60,-25000) is for a $25,000 loan, 5% annual interest, 60 month loan.

erik.van.geit

MrExcel MVP
Joined
Feb 1, 2003
Messages
17,832

MickG

MrExcel MVP
Joined
Jan 9, 2008
Messages
14,841
Hi, Try this:-
Code:
Private [COLOR="Navy"]Sub[/COLOR] Worksheet_Change(ByVal Target [COLOR="Navy"]As[/COLOR] Range)
 [COLOR="Navy"]If[/COLOR] Target.Address(0, 0) = "A1" [COLOR="Navy"]Then[/COLOR]
    [COLOR="Navy"]With[/COLOR] Range("A2")
      [COLOR="Navy"]If[/COLOR] Range("A1") = "MOM" [COLOR="Navy"]Then[/COLOR]
        .Select
        .Validation _
            .Modify xlValidateList, xlValidAlertStop, _
            xlBetween, "=" & Range("B1:B10").Address & ""
     [COLOR="Navy"]ElseIf[/COLOR] Range("A1") = "DAD" [COLOR="Navy"]Then[/COLOR]
        .Select
       .Validation _
            .Modify xlValidateList, xlValidAlertStop, _
            xlBetween, "=" & Range("C1:C10").Address & ""
    [COLOR="Navy"]End[/COLOR] If
  [COLOR="Navy"]End[/COLOR] With
[COLOR="Navy"]End[/COLOR] [COLOR="Navy"]If[/COLOR]
[COLOR="Navy"]End[/COLOR] [COLOR="Navy"]Sub[/COLOR]
Regards Mick
 

Watch MrExcel Video

Forum statistics

Threads
1,123,385
Messages
5,601,331
Members
414,446
Latest member
CRAVIN

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
Top