+ Reply to Thread
Results 1 to 2 of 2

Excel 2003 - VBA - Autofilter, more than 2 criteria?

  1. #1
    Registered User
    Join Date
    04-24-2008
    Posts
    85

    Excel 2003 - VBA - Autofilter, more than 2 criteria?

    Hello all,
    I am trying to autofilter in VBA (Excel 2003), it looks like I am limited to two criteria.. is there a way around this?

    Basically I have a list of users and roles, they can have about 50 different roles, I'm trying to have this macro filter out 4 different roles, and copy these users and their roles to a different sheet.

    I can do it for two of them no problem, and I know that I could do it twice, but I am trying to keep it simple as I am trying to avoid having to copy them to the different sheet, go back, re-autofilter, go to other sheet, find last row, paste below..

    So, basically I know how to do it in a long way, but I also view these as a learning experience so I'm wondering what some experienced people think.. As always, any help you guys can provide is appreciated..

    Thanks!

    Adam
    Last edited by AdamParker; 03-17-2010 at 04:41 PM. Reason: Solved

  2. #2
    Forum Expert romperstomper's Avatar
    Join Date
    08-13-2008
    Location
    England
    MS-Off Ver
    365, varying versions/builds
    Posts
    22,007

    Re: Excel 2003 - VBA - Autofilter, more than 2 criteria?

    Either use an advanced filter (which needs a criteria range) or use an additional formula column that checks to see if each row matches one of your 4 criteria, then autofilter for TRUE in the additional column.
    Everyone who confuses correlation and causation ends up dead.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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