Please Note: This article is written for users of the following Microsoft Excel versions: 2007, 2010, 2013, 2016, 2019, and Excel in Microsoft 365. If you are using an earlier version (Excel 2003 or earlier), this tip may not work for you. For a version of this tip written specifically for earlier versions of Excel, click here: Contingent Validation Lists.
Written by Allen Wyatt (last updated March 6, 2021)
This tip applies to Excel 2007, 2010, 2013, 2016, 2019, and Excel in Microsoft 365
The data validation capabilities in Excel are quite handy, particularly if your worksheets will be used by others. When developing a worksheet, you might wonder if there is a way to make the choices in one cell contingent on what is selected in a different cell. For instance, you may set up the worksheet so that cell A1 uses data validation to select a product from a list of products. You would then like the validation rule in cell B1 to present different validation lists based on the product selected in A1.
The easiest way to accomplish this task is in this manner:
Figure 1. The New Name dialog box.
Figure 2. The Data Validation dialog box.
That's it. Now, whatever is chosen in cell A1 dictates which list is presented in cell B1.
ExcelTips is your source for cost-effective Microsoft Excel training. This tip (11943) applies to Microsoft Excel 2007, 2010, 2013, 2016, 2019, and Excel in Microsoft 365. You can find a version of this tip for the older menu interface of Excel here: Contingent Validation Lists.
Excel Smarts for Beginners! Featuring the friendly and trusted For Dummies style, this popular guide shows beginners how to get up and running with Excel while also helping more experienced users get comfortable with the newest features. Check out Excel 2013 For Dummies today!
When entering data in a worksheet, you may want to exercise some degree of control on the values that can be entered. ...
Discover MoreWant to limit what a person can enter into a particular cell? You can use Excel's data validation feature to help enforce ...
Discover MoreWhen creating a worksheet, you may need to limit what can be entered into a particular cell. Using data validation you ...
Discover MoreFREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."
2022-02-05 08:56:45
Victor
Hi Allen,
I would like to ask if it's possible to do a "circular" form of data validation?
e.g.
column A uses a validation list (i.e. column F contains A,B,C,D,E),
column B uses e.g. Vlookup (i.e. vlookup column F and column G that contains Apple,Bananas,Cherries,Dates,Eggplant) to check if A2="A", then B2=Apple.
What I like to do is to be able to enter Apple in B2 and it fills A2 with "A", so that I can change values in column A or B and it will reflect accordingly.
Thanks in advance!
2021-03-20 14:32:51
Einat Zvirin
This is very good for a 2 dimensional problem. Any suggestions for a more complex 3D or 4D problem?
Thanks
2021-03-06 05:45:08
Mike
Step 12 could become very tedious if you have many columns. Selecting the entire table and choosing Formulas Tab - Defined Names - Create from Selection will deal will all the columns in one go. Just ensure you have Top Row only selected.
Got a version of Excel that uses the ribbon interface (Excel 2007 or later)? This site is for you! If you use an earlier version of Excel, visit our ExcelTips site focusing on the menu interface.
FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."
Copyright © 2024 Sharon Parq Associates, Inc.
Comments