Link to home
Start Free TrialLog in
Avatar of Shanan212
Shanan212Flag for Canada

asked on

Filter multiple criteria with VBA

ActiveSheet.Range("$B$3:$C$523").AutoFilter Field:=1
    ActiveSheet.Range("$B$3:$C$523").AutoFilter Field:=1, Criteria1:=Array( _
        "ACKLANDS*", "ARTISTS*", "AVANDIUM*", _
        "BASIN*", "BIG*", "BONDY*"), Operator:=xlFilterValues

Open in new window


Hi,

I have the above line of code which is not working. What I want is to have a filtered list which has all of the words which starts with the words in the above array.

When I run the cide, it just hides all data although there are clearly data available to be filtered.

Any help is much appreciated!
Avatar of Barry62
Barry62
Flag of United States of America image

Could you give us some data so we can debug your code?
Avatar of Shanan212

ASKER

Hi,

See attached for the sample sheet.
Sample-Data.xlsx
ASKER CERTIFIED SOLUTION
Avatar of byundt
byundt
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thanks!