Forum Discussion
Splicer on 2 columns
I understand your situation. You want to filter data based on a year range using a slicer in Excel.
Unfortunately, Excel slicers don’t directly support filtering by a range of values. However, there are some workarounds you can consider:
Helper Column: Create a helper column for each year within the range.
For example, if your range is 2008-2012, create columns for 2008, 2009, 2010, 2011, and 2012.
Mark each column with a ‘1’ if the year falls within the range and ‘0’ otherwise.
Then, you can use a slicer on these helper columns.
Pivot Table: Create a pivot table from your data and use a timeline slicer. This will allow you to filter by a range of dates.
VBA Macro: Write a VBA macro to create a custom slicer that filters based on your criteria. This requires some knowledge of VBA and might be more complex than the other solutions.
Remember to always back up your data before trying these solutions