Using autofilter to trigger an event

K

Kevin B

I have a macro that I want to execute every time an Autofilter is updated in
an Excel workbook, but updating an Autofilter does not trigger the workbook
SheetChange event or the worksheet Change event. Can anyone point me in a
direction I need to look in?


Thanks…
 
B

Bernie Deitrick

Kevin,

You could use a cell with a SUBTOTAL formula call to the filtered range and the worksheet's
calculate event will then fire when the autofilter is changed.

HTH,
Bernie
MS Excel MVP
 
K

Kevin B

Many thanks Bernie for such a straightforward solution, I was making it a
bit more complicated than it turned out to be.

Thanks, you've saved me a lotta' time...
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top