+ Reply to Thread
Results 1 to 3 of 3

Autofilter for multiple column

  1. #1
    Registered User
    Join Date
    11-16-2023
    Location
    Singapore
    MS-Off Ver
    Microsoft 365
    Posts
    2

    Autofilter for multiple column

    Hi, I'm trying to do a filter on change in a textbox such that if it contains the value in any of 2 column it will remain in the table.
    For this example, the value user entered is a, so I would like to retain the entry as long as it has a appearing in either or both column.
    My codes are as follows but it doesn't work. It will only return results that contain the value in column A:
    Please Login or Register  to view this content.
    Value 1 Value 2 Result
    a b Retain
    b a Retain
    a a Retain
    b b Filter Out

  2. #2
    Registered User
    Join Date
    11-16-2023
    Location
    Singapore
    MS-Off Ver
    Microsoft 365
    Posts
    2

    Re: Autofilter for multiple column

    Is there no solution available?

  3. #3
    Registered User
    Join Date
    04-18-2023
    Location
    Adelaide, Australia
    MS-Off Ver
    365
    Posts
    10

    Re: Autofilter for multiple column

    It would be easier if the data was in a range, rather than a table, as you could use advanced filter to achieve what you seem to be after. Try the code below on a copy of your workbook. It assumes the criteria is in cell I4 (as per your original post). 2 codes provided. The first deals with a table, the second with a range.

    Please Login or Register  to view this content.

+ 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. Autofilter a column by multiple checkboxes in userform
    By impresxy in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 05-27-2021, 08:17 AM
  2. [SOLVED] Autofilter to delete multiple rows with multiple variables
    By Ravana in forum Excel Programming / VBA / Macros
    Replies: 15
    Last Post: 03-10-2015, 12:01 AM
  3. [SOLVED] AutoFilter with multiple criteria in a single column
    By Faridwahidi in forum Excel Programming / VBA / Macros
    Replies: 20
    Last Post: 07-23-2014, 12:45 PM
  4. Autofilter multiple columns with multiple string criteria
    By svalentine91 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 12-23-2013, 11:26 AM
  5. [SOLVED] Multiple AND search on a column using Autofilter?
    By I-Like-Excel in forum Excel General
    Replies: 4
    Last Post: 04-22-2013, 02:27 AM
  6. multiple column , multiple criteria autofilter sort
    By jseufert in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-28-2009, 06:18 PM
  7. Replies: 1
    Last Post: 01-23-2006, 02:25 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