Dynamic Drop-Down Lists for Dates and Check Numbers

by on April 29, 2013

6 Comments |  
 |   Email |  
 Print |  
 Share |  

If you use Excel for money management or any type of activity where you are entering daily transactions or logging daily activities, then you may find it useful to create a dynamic drop-down list. This technique came about through the use of the Money Management template, so I will use that template as an example.

In the money management template, the Transactions worksheet provides a table for entering bank and credit card transactions, just like you would find in any check register or personal finance software. When we add new transactions, we want to be able to select the next date and next check number from a drop-down list as shown in the images below.

Dynamic Drop Down List for Dates
Dynamic drop-down list for Dates
Dynamic Drop Down List for Next Check Numbers
Dynamic drop-down list for Check Numbers

The list of dates includes the most recent date plus the dates for the next week. It would be much better if Microsoft provided a convenient built-in date picker tool, but this approach provides a useful substitute for now. We can still enter the date manually if we want to.

As you may know from your own experience, checks that you write are not always deposited in the order you write them. So, for the drop down list in the Num column, we can list the next three check numbers. (Note: after writing this article and creating these images, I found that I also wanted to list the previous two check numbers).

Setting up the Dynamic Drop-Down Lists

Step 1: Create the lists

The lists used for the dynamic drop-downs need a home, so for this example we can create a new worksheet and create the lists as shown in the image below. The formula in A6 is adding +1 to the current maximum check number in the Num column. Cell C2 is finding the most recent date in the Date column. The rest of the items in the list are just calculated from those two cells as shown.

Formulas for the Drop Down Lists
Formulas for the drop down lists

Step 2: Name the lists

The next step is to name the ranges “num_list” and “date_list” by selecting the list (not including the header in row 1) and using the Name Box to name the ranges as shown in the next image.

Creating the Named Ranges
Naming the lists

It isn’t necessary to use named ranges when creating drop-down lists, but if you ever want to redefine the list, it’s easier to redefine the named range than to update all the cells that use data validation to refer to the list. That brings us to the last step.

Step 3: Create the in-cell drop-downs

To set up the data validation drop-down lists, just select all of the cells in the Num column and go to Data > Data Validation, select List from the Allow field, and enter =num_list in the Source field, as shown in the image below. Do likewise for the Date cells to reference the date_list range.

Data Validation Settings
Data Validation Settings
Important: To Avoid the Data Validation Error Message …

It’s important that when you set up the data validation drop down list you uncheck the “Show error alert after invalid data is entered” in the Error Alert tab. This allows you to still enter any check number of date that you want, without Excel popping up an error warning.

That is really all there is to it. If you find other uses for this technique, please let me know.

VN:F [1.9.22_1171]
Rating: 5.0/5 (2 votes cast)
Dynamic Drop-Down Lists for Dates and Check Numbers, 5.0 out of 5 based on 2 ratings

{ 6 comments… read them below or add one }

Leave a Comment

Previous post:

Next post: