国产av日韩一区二区三区精品,成人性爱视频在线观看,国产,欧美,日韩,一区,www.成色av久久成人,2222eeee成人天堂

Table of Contents
Quick Links
Using a Column in a Formatted Excel Table
Method 1: Reference the Cells in the Table
Using a Column in an Unformatted Dataset
Home Software Tutorial Office Software How to Create a Drop-Down List from a Column of Data in Excel

How to Create a Drop-Down List from a Column of Data in Excel

Jun 07, 2025 am 06:02 AM

  • Using a Column in a Formatted Excel Table

  • Using a Column in an Unformatted Dataset

Microsoft Excel's Data Validation tool enables you to add a drop-down list to a cell based on existing data in a column. However, how this functionality operates depends on whether the source data is part of a formatted Excel table. Let's explore some examples.

Using a Column in a Formatted Excel Table

Suppose you have this formatted Excel table called "Scores," which includes player names, nations, and scores, and you need to extract some summary data. Specifically, in cell H2, you want to create a drop-down list of all the nations listed in column B, and in cells I2 and J2, display the player names and average score, respectively, according to the nation selected.

How to Create a Drop-Down List from a Column of Data in Excel

To create a drop-down list, select the cell where you want it to be (in this case, cell I2), and in the Data tab on the ribbon, click "Data Validation" in the drop-down option with the same name.

How to Create a Drop-Down List from a Column of Data in Excel

How to Create a Drop-Down List from a Column of Data in Excel

Related ##### How to Add a Drop-Down List to a Cell in Excel

It saves you the trouble of typing in the same options 200 different times manually.

Then, in the Allow field of the Settings tab, select "List."

How to Create a Drop-Down List from a Column of Data in Excel

The next step involves entering the options you want to appear in the drop-down list into the Source field. To do this, you can type the options manually, select the relevant cells on your spreadsheet, or use a formula.

Ideally, you would be able to type:

<code>=Scores[Nation]</code>

into the Source field, just as you would when referencing that column in a formula, where "Scores" represents the table name, and "Nation" represents the column header. However, unfortunately, this returns an error message, as the data validation tool only recognizes cell references, formulas, and named ranges as data sources, not table column headers.

How to Create a Drop-Down List from a Column of Data in Excel

Luckily, there are two ways to get around this.

Method 1: Reference the Cells in the Table

First, activate the "Source" field in the Data Validation dialog box so that the cursor is flashing, and hover over the relevant column header in row 1 until you see a small, black down arrow. When you do, click once to select all the data cells in that column.

How to Use the FILTER Function in Microsoft Excel There’s more than one way to filter your data.

Finally, use the AVERAGEIF function in cell J2 to display the average score of players from this nation:
<code>=AVERAGEIF(Scores[Nation],H2,Scores[Total])</code>

How to Create a Drop-Down List from a Column of Data in Excel

How to Create a Drop-Down List from a Column of Data in Excel

Related ##### How to Use the AVERAGEIF and AVERAGEIFS Functions in Excel

Be selective about what to include in your average calculations.

### Method 2: Name the Range

The second way to create a drop-down list from a column in a formatted table involves naming the source range.

Before launching the Data Validation dialog box, select all the cells in the table that contain the values you want to include in the drop-down list, type a name for the range in the name box in the top-left corner of the Excel window, and press Enter.

I Always Name Ranges in Excel, and You Should Too Tidy up your Excel workbook.

Now, as with method 1, you can use the FILTER and AVERAGEIF functions to complete the data extraction.

However, this time, the formulas can be more straightforward, as you can reference the range you named "Nation" without referencing the table the range is in.

So, for FILTER in cell I2, it's:

<code>=FILTER(Scores[Player],Nation=H2)</code>

and for AVERAGEIF in cell J2, it's:

<code>=AVERAGEIF(Nation,H2,Scores[Total])</code>

Using a Column in an Unformatted Dataset

Certain types of data—like spilled arrays—cannot be formatted as an Excel table, so there may be times when you need to find a way to create a drop-down list from a column within an unformatted dataset.

After selecting the cell that will contain the drop-down list and clicking "Data Validation" in the Data tab on the ribbon, select "List" in the Allow field.

How to Create a Drop-Down List from a Column of Data in Excel

Next, in the Source field, use the INDIRECT and COUNTA functions together to tell Excel where to find the options for the drop-down list.

In this case, typing:

<code>=INDIRECT("B2:B"&COUNTA(B:B))</code>

includes all the values in column B from cell B2 to cell B22 as the source.

How to Create a Drop-Down List from a Column of Data in Excel

Let's break this source formula down to see how it works.

  • =INDIRECT(: This tells Excel that you want the source to be determined using a dynamic reference.
  • "B2:B": Specifically, the dynamic reference starts at cell B2, and ends at another cell in column B.
  • &COUNTA(B:B)): This counts all the cells in column B that aren't blank, and adds the total to the reference. In this case, 22 cells in column B contain values, so this turns B2:B into B2:B22.

How to Create a Drop-Down List from a Column of Data in Excel

Related ##### How to Use the INDIRECT Function in Excel

Use a text string to create a reference.

2 So, if you add another row of data at the bottom, the COUNTA function will pick this up and inform the INDIRECT reference in the data validation rule that the source has expanded downwards by an extra row.

How to Create a Drop-Down List from a Column of Data in Excel

Using a formula to determine which values to include in the data validation source—rather than simply selecting the whole column—is considered best practice as it prevents the header row and blank rows from being included in the drop-down list.

You can double-check this by selecting the cell that hosts the drop-down list, and reopening the Data Validation dialog box. When you select the Source field, even though the formula hasn't changed, the dotted line on the spreadsheet confirms that it picks up the new values in the added row.

How to Create a Drop-Down List from a Column of Data in Excel

Now that your drop-down list is ready to go, use the INDIRECT and COUNTA functions alongside the FILTER function in cell I2 and the AVERAGEIF function in cell J2 to complete the spreadsheet.

How to Create a Drop-Down List from a Column of Data in Excel


Drop-down lists added through the Data Validation tool are incredibly powerful and versatile, and can be used in many scenarios in Excel. For example, you can use drop-down lists to make regular charts dynamic—a surefire way to impress your friends and coworkers.

The above is the detailed content of How to Create a Drop-Down List from a Column of Data in Excel. For more information, please follow other related articles on the PHP Chinese website!

Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undress AI Tool

Undress AI Tool

Undress images for free

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

Hot Topics

PHP Tutorial
1502
276
how to group by month in excel pivot table how to group by month in excel pivot table Jul 11, 2025 am 01:01 AM

Grouping by month in Excel Pivot Table requires you to make sure that the date is formatted correctly, then insert the Pivot Table and add the date field, and finally right-click the group to select "Month" aggregation. If you encounter problems, check whether it is a standard date format and the data range are reasonable, and adjust the number format to correctly display the month.

How to Fix AutoSave in Microsoft 365 How to Fix AutoSave in Microsoft 365 Jul 07, 2025 pm 12:31 PM

Quick Links Check the File&#39;s AutoSave Status

How to change Outlook to dark theme (mode) and turn it off How to change Outlook to dark theme (mode) and turn it off Jul 12, 2025 am 09:30 AM

The tutorial shows how to toggle light and dark mode in different Outlook applications, and how to keep a white reading pane in black theme. If you frequently work with your email late at night, Outlook dark mode can reduce eye strain and

how to repeat header rows on every page when printing excel how to repeat header rows on every page when printing excel Jul 09, 2025 am 02:24 AM

To set up the repeating headers per page when Excel prints, use the "Top Title Row" feature. Specific steps: 1. Open the Excel file and click the "Page Layout" tab; 2. Click the "Print Title" button; 3. Select "Top Title Line" in the pop-up window and select the line to be repeated (such as line 1); 4. Click "OK" to complete the settings. Notes include: only visible effects when printing preview or actual printing, avoid selecting too many title lines to affect the display of the text, different worksheets need to be set separately, ExcelOnline does not support this function, requires local version, Mac version operation is similar, but the interface is slightly different.

How to Screenshot on Windows PCs: Windows 10 and 11 How to Screenshot on Windows PCs: Windows 10 and 11 Jul 23, 2025 am 09:24 AM

It's common to want to take a screenshot on a PC. If you're not using a third-party tool, you can do it manually. The most obvious way is to Hit the Prt Sc button/or Print Scrn button (print screen key), which will grab the entire PC screen. You do

Where are Teams meeting recordings saved? Where are Teams meeting recordings saved? Jul 09, 2025 am 01:53 AM

MicrosoftTeamsrecordingsarestoredinthecloud,typicallyinOneDriveorSharePoint.1.Recordingsusuallysavetotheinitiator’sOneDriveina“Recordings”folderunder“Content.”2.Forlargermeetingsorwebinars,filesmaygototheorganizer’sOneDriveoraSharePointsitelinkedtoaT

how to find the second largest value in excel how to find the second largest value in excel Jul 08, 2025 am 01:09 AM

Finding the second largest value in Excel can be implemented by LARGE function. The formula is =LARGE(range,2), where range is the data area; if the maximum value appears repeatedly and all maximum values ??need to be excluded and the second maximum value is found, you can use the array formula =MAX(IF(rangeMAX(range),range)), and the old version of Excel needs to be executed by Ctrl Shift Enter; for users who are not familiar with formulas, you can also manually search by sorting the data in descending order and viewing the second cell, but this method will change the order of the original data. It is recommended to copy the data first and then operate.

how to get data from web in excel how to get data from web in excel Jul 11, 2025 am 01:02 AM

TopulldatafromthewebintoExcelwithoutcoding,usePowerQueryforstructuredHTMLtablesbyenteringtheURLunderData>GetData>FromWebandselectingthedesiredtable;thismethodworksbestforstaticcontent.IfthesiteoffersXMLorJSONfeeds,importthemviaPowerQuerybyenter

See all articles