Creating A Validation List From Unique Values in A Column (Filtered and unfiltered)

Ark68

Well-known Member
Joined
Mar 23, 2004
Messages
4,564
Office Version
  1. 365
  2. 2016
Platform
  1. Windows
I am looking for a VBA solution that can analyze a column (A) in a worksheet (F_FUNC) to create a list of unique values. This list of unique values will form the list of a cell validation list. I know I can step through each cell in the column, and compile a unique value list in a column on another worksheet, and define that range of values for the validation list. But I'm wondering if thereis a more efficient method.

On a side not, how would this same process work on a filtered list? For example, if I filtered a single value in column A, how would I create a validation list of the unique values in column B as a result of the filter?
 

Excel Facts

What do {} around a formula in the formula bar mean?
{Formula} means the formula was entered using Ctrl+Shift+Enter signifying an old-style array formula.
If you are using 365, use the UNIQUE function and create the list in another range.
 
Upvote 1
Thanks RoryA, I'll give it a try. But before I put too much effort into trial and error, would this work if the data is filtered?

I found this option as well, but again, fear it won't work on filtered data. (
)
 
Upvote 0
would this work if the data is filtered
Yes, you can handle that by adding in SUBTOTAL, or adding the same criteria into a FILTER function inside the UNIQUE function.
 
Upvote 0

Forum statistics

Threads
1,215,073
Messages
6,122,970
Members
449,095
Latest member
Mr Hughes

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top