+ Reply to Thread
Results 1 to 3 of 3

remove all active filters in workbook

  1. #1
    Forum Contributor
    Join Date
    04-04-2016
    Location
    dallas tx
    MS-Off Ver
    365 (15.0.5501.1000)
    Posts
    534

    remove all active filters in workbook

    I tried recording a macro where I went to each worksheet in my workbook and cleared the active filters but when I run the macro later if the page does not have an active filter then I get an error message. Is there a way around this so that the macro will clear all active filters on a page while ignoring the page if it does not have any filters currently applied?

  2. #2
    Forum Expert CK76's Avatar
    Join Date
    06-16-2015
    Location
    ONT, Canada
    MS-Off Ver
    MS365 Apps for enterprise
    Posts
    5,885

    Re: remove all active filters in workbook

    If it's autofilter on regular range. Something like below.

    Please Login or Register  to view this content.
    ?Progress isn't made by early risers. It's made by lazy men trying to find easier ways to do something.?
    ― Robert A. Heinlein

  3. #3
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,167

    Re: remove all active filters in workbook

    Hi chris,

    It seems to me this is a good place to use "On Error Resume Next" in your code.

    https://docs.microsoft.com/en-us/dot...rror-statement
    One test is worth a thousand opinions.
    Click the * Add Reputation below to say thanks.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 1
    Last Post: 08-01-2017, 05:09 PM
  2. [SOLVED] VBA to prevent saving with filters active
    By spreadsheetlackey in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-14-2017, 09:27 AM
  3. [SOLVED] Code to detect previous active workbook instead of current active workbook
    By kosherboy in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 02-25-2014, 01:58 AM
  4. Replies: 4
    Last Post: 07-24-2012, 01:21 PM
  5. How to remove all filters in workbook before running code?
    By Motox in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 02-23-2012, 03:42 AM
  6. Remove all code and modules from the active workbook
    By dasvas in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 02-09-2011, 11:26 PM
  7. [SOLVED] Finding active filters in Excel.
    By topjmy in forum Excel General
    Replies: 0
    Last Post: 12-01-2005, 11:35 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1