Data validation question

rjc4

Well-known Member
Joined
Nov 6, 2004
Messages
502
Hi All,

RangeA
Cell Y1 contains text of OPT1
Cell Y2 contains text of OPT2
RangeB
Cell Z4 contains text of USER1
Cell Z5 contains text of USER2

In M5 is a dropdown containing choices of YES or NO.

In H8, how can I use data validation to show me only range Y1:Y2 if M5 is YES and range Z4:Z5 if M5 is NO.

I guess it requires a custom formula in the data validation setup but I can't get it to work. Could anyone help please!

Thanks,
RC :oops:
 

Some videos you may like

Excel Facts

Select a hidden cell
Somehide hide payroll data in column G? Press F5. Type G1. Enter. Look in formula bar while you arrow down through G.

BJungheim

Well-known Member
Joined
Jul 24, 2004
Messages
914
Select Y1:Y2, go to Insert|Name|Define and call this range Yes.

Select Z4:Z5, go to Insert|Name|Define and call this range No.

Select Range H8, go to Data|Validation, select Lists in the first dropdown, and in the source box put =INDIRECT(M5).

This will change your data validation list based on what is in M5.

Keep in mind that this will not prevent someone from setting H8 and then changing M5.
 

rjc4

Well-known Member
Joined
Nov 6, 2004
Messages
502
Thankyou very much BJungheim for your prompt solution. Fits the bill perfectly.

Kind regards,
RC :biggrin: :biggrin: :biggrin:
 

Watch MrExcel Video

Forum statistics

Threads
1,122,850
Messages
5,598,446
Members
414,240
Latest member
xnanx

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