Method 1 – Make a Dynamic Drop-Down List to Link a Cell Value
We have a list of Item Names of some computer accessories. We will make a dynamic drop-down list from it.
Steps:
- Select a cell where you want to make the list (i.e. D5).
- Go to the Data tab and click on Data Validation.
- The Data Validation dialogue box will appear.
- Select “List” as the validation criteria.
- In the source field, insert the following formula:
=OFFSET($B$4,0,0,COUNTIF($B$4:$B$100,”<>”))
- Reference is $B$5
- Rows and Columns are 0
- [height] is COUNTIF($B$5:$B$100,”<>”)
- Click OK to get the drop-down list.
- Delete some data from your data list.
- Open the drop-down list and see that the list has been updated.
- If we insert some values to the list (by inserting rows in the range), the drop-down will also add these values.
Method 2 – Make a Dependent Drop-Down List to Link a Cell Value
Consider this example where the “Hardware” and “Software” columns are given with some data. We need to make a dependent list, allowing us to select the category and then the item in two lists.
Steps:
- Select cell E5 and go to the Data tab.
- Select Data Validation from the Data Tools group.
- Select List as validation criteria.
- In the source field, assign the value =$B$4:$C$4.
- Click OK to make the list.
- We have our drop-down list for the columns.
- Select the two original columns.
- Go to Formula and, in the “Name Manager, click on Create From Selection.
- A new window pops out. Check Top Row and click OK.
- Click on Close.
- Select cell F4 and go to Data Validation.
- Select List for Allow.
- In the Source box, insert the following:
=INDIRECT(E4)
- Click OK.
- When you select Hardware in the drop-down list E3, this refers to the named range Hardware (through the INDIRECT function) and thus lists all the items in that category.
- Add or delete values from the source list and the drop-down list will update.
Read More: How to Create Drop Down List with Filter in Excel
Method 3 – Using the VLOOKUP Function to Link a Cell
We have a list of Item names and their Prices. We will make a drop-down list and link the cell values with the list using the VLOOKUP function.
Steps:
- Make a drop-down list in the cell E5 by following Method 1, using the source data as the cells of the Item Name column.
- Apply the VLOOKUP function in the cell F5. The formula is:
=VLOOKUP(E4,B4:C23,2,FALSE)
- Lookup_Value is E5 (The drop-down list)
- Table_Array is B5:C22
- Col_Index_Num is 2
- We want the exact value (FALSE)
- Press Enter.
- You can change the list value and check that the cells are linked.
Read More: How to Add Item to Drop-Down List in Excel
Method 4 – Using the SUMIF Function to Link a Cell
We will use the previous example.
- Create a drop-down for Item Name like in Method 1.
- In the cell F5 apply the following formula:
=SUMIF(B5:B22,E5,C5:C22)
- Range is B4:B22
- Criterion is E5
- [Sum_range] is C4:C23
Method 5 – Make a Hyperlink Drop-Down List to Link a Cell Value
We have two worksheets named Hardware and Software. One of them has data for Hardware.
The other contains the data for Software.
Steps:
- Create another worksheet and open it.
- Make a Category column where you will insert the worksheet name that you want to link with the list.
- In cell E4, make the drop-down list for Hardware and Software.
- Select the drop-down list cell, go to Formula, and click on Name Manager.
- Click on New to give this cell a new name.
- Name the E4 cell Worksheet_Link and click OK.
- Select cell E4 and press CTRL + K to create a link in this cell.
- In the new window, select Place in the Document, click on Worksheet_Link, and press OK.
- We will edit the link of this cell.
- Select the drop-down list cell, go to Formula, and click on Name Manager.
- Select Worksheet_Link and click Edit.
- In the Refers to field, insert the following formula:
=INDIRECT(ADDRESS(4,5,,,E4))
- [ref_text] is ADDRESS(4,5,,,E4)
The ADDRESS function is
=ADDRESS(4,5,,,E4)
- Row_num is 4 for the linked worksheet.
- Col_Num is 5 for the linked worksheet
- [abs_num], [a1] is ignored
- [sheet_text] is E4.
- Click OK.
- The worksheets are linked with the drop-down list.
- We want to go to the Hardware sheet. Select Hardware from the list and click on it.
- Excel opens the Hardware sheet.
Read More: How to Create a Drop Down List From Another Sheet in Excel
Things to Remember
⏩ While creating a dynamic drop-down list, make sure that the cell references are absolute (such as $B$4) and not relative (such as B2, or B$2, or $B2)
⏩ In the hyperlink drop-down list, the [abs_num], [a1] are ignored. Put (,,) to do that.
⏩ To avoid errors, check “Ignore Blank” and “In-cell Dropdown”.
Download the Practice Workbook
Related Articles
- Create Excel Drop Down List from Table
- How to Remove Drop Down List in Excel
- How to Create Excel Drop Down List with Color
- How to Create a Drop Down List with Unique Values in Excel
- How to Copy Filter Drop-Down List in Excel
- Excel Drop Down List Not Working
<< Go Back to Excel Drop-Down List | Data Validation in Excel | Learn Excel
Get FREE Advanced Excel Exercises with Solutions!
“Source Validates to an error” every time. Whether I use my own data and change the numbers, or match this perfectly. Not sure what I’m doing wrong when I copy directly, but I’ve followed a dozen different tutorials (At least), used existing sheets, creating sheets from scratch, you name it. Same error every time.
Dear MIKE WELLS,
Thanks for your response.
There are several reasons behind this “Source Validates to an error” occurring. You can solve them efficiently providing the correct data inside the string.
Reason: The source validates that an error can occur if the source to which the formula is applied demonstrates an error. Thus the final statement stands to whether the formula is not correct or the formula refers to data returning an error.
Solve: To solve this problem, you have to provide correct data or change the formula.
From our dataset, suppose we are having trouble with the “Source Validates to an error“. This error is occurring due to the blank cell (E4). As the INDIRECT function converts a string into an actual reference thus finding the reference cell (E4) blank it’s showing an error. Check the following screenshot.
In order to solve this just put the same text from the list in the reference cell and you won’t find any more errors further.
Other reasons behind this “Source Validates to an error” might happen-
a) The applied formula is not the proper formula to find the references.
b) Put exact names from the list to the reference list to avoid errors.
Hope you will find your solution with this reply. If you are still having problems, don’t hesitate to let us know below. We are always here with you to solve your problems. Thanks!