Advanced Filter Auto refresh

smartpat19

Board Regular
Joined
Sep 3, 2014
Messages
114
I am trying to automatically update this advanced filter when the criteria is changed ("A2:I2"), my code is below. I'm trying to keep the source data in a table since this will always be updated with new data, but if there's another solution, let me know. Thanks.

Code:
Private Sub Worksheet_Change(ByVal Target As Range) Sheets("Filtered Data").ListObjects("Table2").Range.AdvancedFilter xlFilterCopy, Sheets("Anchored Retail").Range("A2:I2"), Range("A5:I5")
End Sub

Windows 7, Excel 2013.
 
Last edited:

Excel Facts

Create a chart in one keystroke
Select the data and press Alt+F1 to insert a default chart. You can change the default chart to any chart type
WOW! i just figured it out! my criteria range was off! should be ("A2:I3")

However, is there a way to put the advanced filter output into a table? or could I add some VBA to this "worksheet change Sub" to change a range reference?
 
Upvote 0

Forum statistics

Threads
1,217,070
Messages
6,134,412
Members
449,872
Latest member
Big Jake

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