Function Problems

How to Auto-Fill Data Based on an Excel Drop-Down List Selection

Camila MilosovichCamila Milosovich Oct 21, 2026 870 views

Question details

The user needs to create a drop-down list that automatically populates adjacent cells with associated saved data when a specific item is selected.

How to Auto-Fill Data Based on an Excel Drop-Down List Selection
Product
Excel / WPS Spreadsheet
Device & OS
not provided
Scenario
Designing a dynamic form or template where selecting an item from a drop-down menu automatically pulls corresponding details (like prices, descriptions, or IDs) from a master lookup table.
Observed behavior
The user requires a method to link the drop-down list selection to a database table so that related output cells update automatically without manual data entry.
Before you start

Ensure your source data is organized into a clean table with no blank rows, and that the items intended for your drop-down list are completely unique to prevent the formula from fetching incorrect values.

Solution 1Recommended

Combine Data Validation with Lookup Formulas

Create a master lookup table and link it to your drop-down list using standard lookup formulas (VLOOKUP or XLOOKUP) to automatically retrieve related data.

This method involves two main parts: using Data Validation to restrict cell input to a specific list of items, and using a lookup function like VLOOKUP or XLOOKUP to fetch the corresponding details from your master table based on the selected item.

1
Prepare the source data table

On a separate sheet or off to the side of your main work area, create a lookup table. Place the items you want in your drop-down list in the first column, and place the related data (e.g., price, employee ID, category) in the adjacent columns.

2
Create the drop-down list

Select the cell where you want the drop-down menu to appear. Go to the 'Data' tab on the ribbon and click 'Validation' (or 'Data Validation'). Under the 'Allow' drop-down, choose 'List'. In the 'Source' box, highlight the first column of your source data table, then click 'OK'.

3
Apply the lookup formula to target cells

In the cell where you want the saved data to appear automatically, enter a formula like =VLOOKUP(A1, SourceTable!A:D, 2, FALSE). In this example, 'A1' is your drop-down cell, 'SourceTable!A:D' is your source data range, and '2' is the column index containing the specific data you want to display.

Combine Data Validation with Lookup Formulas
Tip for Modern Excel and WPS Users: Using the XLOOKUP function (e.g., =XLOOKUP(A1, SourceTable!A:A, SourceTable!B:B)) is highly recommended because it defaults to an exact match and will not break if you insert or delete columns in your source table.

Easily Build Interactive Spreadsheets with WPS Office

WPS Spreadsheet provides intuitive tools for Data Validation and fully supports advanced Excel functions like XLOOKUP and VLOOKUP, allowing you to create dynamic, auto-filling forms effortlessly.

  1. 1. Open WPS Spreadsheet: Launch WPS Office and open your workbook or create a new one to prepare your source data.
  2. 2. Set Up Data Validation: Navigate to the Data tab, click 'Validation', and select 'List' to create your drop-down menu referencing your source data column.
  3. 3. Insert the Lookup Formula: Type =XLOOKUP() or =VLOOKUP() into your target output cell, using your new drop-down cell as the primary lookup value.
Fully compatible with Microsoft Excel (.xlsx) formats and standard formulasIntuitive Data Validation interface for quick and easy drop-down creationComprehensive built-in formula library including VLOOKUP, HLOOKUP, and XLOOKUPFree and lightweight alternative to Microsoft Office
microsoft office alternative - wps office

Frequently Asked Questions

Why is my lookup formula returning an #N/A error after making a selection?

The #N/A error occurs when the lookup function cannot find an exact match in the source table. Ensure there are no hidden trailing spaces in your drop-down list or source data cells. Also, confirm that your VLOOKUP formula ends with 'FALSE' or '0' to mandate an exact match.

How do I update my drop-down list when I add new rows to the source data?

To make your drop-down list update automatically, format your source data as a Table (select the data and press Ctrl+T). When you use the Table column as your Data Validation source, any new rows added to the bottom of the table will automatically appear in your drop-down menu.

Can I return multiple columns of data from a single drop-down selection?

Yes. If you use the XLOOKUP function, you can set the return array to encompass multiple columns (e.g., SourceTable!B:D), and the data will dynamically spill into the adjacent cells. If you are using VLOOKUP, you will need to write separate formulas in each target cell, manually changing the column index number for each one.