Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 03-10-2018, 07:23 AM
LearnerExcel LearnerExcel is offline How to select multiple criteria from same column? Windows 7 32bit How to select multiple criteria from same column? Office 2013
Advanced Beginner
How to select multiple criteria from same column?
 
Join Date: Nov 2016
Posts: 81
LearnerExcel will become famous soon enoughLearnerExcel will become famous soon enough
Default How to select multiple criteria from same column?

How can I select multiple criteria from the same column?

The following code works fine for single criteria (I added one line code in red font but it filters only the West region data):



Sub FilterRegion()
With Sheet1
.AutoFilterMode = False
.Range("A2:N2").AutoFilter
.Range("A2:N2").AutoFilter Field:=1, Criteria1:="East"
.Range("A2:N2").AutoFilter Field:=1, Criteria1:="West" 'How to modify the code here.
End With
End Sub
Reply With Quote
  #2  
Old 03-10-2018, 07:41 AM
NoSparks NoSparks is offline How to select multiple criteria from same column? Windows 7 64bit How to select multiple criteria from same column? Office 2010 64bit
Excel Hobbyist
 
Join Date: Nov 2013
Location: British Columbia, Canada
Posts: 831
NoSparks is just really niceNoSparks is just really niceNoSparks is just really niceNoSparks is just really niceNoSparks is just really nice
Default

Do it manually while recording with the macro recorder and have a look at the code it produces.
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
I need to count based on multiple criteria in multiple columns rachaels54 Excel 1 04-18-2017 03:20 PM
How to select multiple criteria from same column? Sum based on multiple criteria (one of the criteria is not unique) until a threshold is reached. phillipsdp Excel 1 11-09-2016 12:53 AM
Select value from table based on two criteria gebobs Excel 4 07-21-2016 08:26 AM
How to select multiple criteria from same column? I need to add multiple values based on multiple criteria in a cell not sure what to do AUHAMM Excel 3 10-27-2014 09:11 PM
How to select multiple criteria from same column? Copy Multiple Rows to new workbook when multiple criteria is met. flds Excel Programming 5 09-30-2014 09:58 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 04:18 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft