Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6246077
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T12:37:23+00:00 2026-05-24T12:37:23+00:00

I have a public following sub in my code as shown below: Public Sub

  • 0

I have a public following sub in my code as shown below:

Public Sub ResetFilters(ByRef tbl As ListObject)
    With tbl

        '// If Filter Arrows are OFF - turns them on
        '// If Filter Arrows are ON - turns them off and resets filter
        .Range.AutoFilter

        '// Always turns filter arrows to on and sorts table by first field
        .Range.AutoFilter Field:=1
    End With
End Sub

As you can See I make use of Excel Tables (ListObjects in vba speak) so I pass the reference into the sub, and it is supposed to reset the table to an unfiltered state. It works fine on a PC with Excel 2007 but fails on Excel 2011 on a Mac with:

Method ‘Autofilter’ of Object ‘Range’ failed

The following link for Excel 2011 VBA Reference shows the AutoFilter Method of the Range object and it matches what I can see in the references for Excel 2007 VBA References.

So can anyone see why this is failing?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T12:37:24+00:00Added an answer on May 24, 2026 at 12:37 pm

    It doesnt seem there have been alot of people jumping at this question… At any rate, if anyone else is interested, I think I found a workaround using the ListObject.ShowAutoFilter property. It is a read/write boolean property and when turned off, it will reset the filters in the ListObject. It has the added bonus of working on both Excel 2011 for Mac and Excel 2007 (and 2010 for that matter) on PC’s.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have the following code: Imports MySql.Data.MySqlClient Imports MySql.Data.Types Public Class FormMain Private Sub
I have the following code: Public Class TestClass Public Sub Main() If theGlobal IsNot
I have the following code: <TestMethod()> _ Public Sub GetDirectoryEntryTest() Dim path As String
I have the following code: Imports System.IO Public Class Blah Public Sub New() InitializeComponent()
I have the following code; Public Sub writetofile() ' 1: Append playername Using writer
I have following code: public static void ProcessStep(Action action) { //do something here if
I have following code public class TEST { public static void main(String arg[]){ try
I have a following code which works fine MsgBox(AddSomething(Of String)(Hello, World)) Public Function AddSomething(Of
I have the following code: Imports System.Data Partial Class Students_AddWishes Inherits System.Web.UI.Page Public dt
How would I test the following code? Public Sub SetSerialIdForDevice() Try Dim component As

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.