Filter Conditions?
Posted by RoB on August 16, 2001 3:08 PM
Thanks to Barrie, I have this code which uses autofilter to copy the user specified conditions. I want to know if there is a way for the user to specify multiple conditions when asked. Is there a way for the user to do this? or in the macro?
Here is the applicable code:
'Get the filter's criteria from the user
FilterCriteria = InputBox("Enter the Condition to Sort out:")
'Filter the data based on the user's input
Selection.AutoFilter field:=ColumnFilterSelect, Criteria1:=FilterCriteria
'Copies Defined Range and pastes on "Prelim Sort" Sheet
Sheets(CurrentSheetName).Range(RangeSelect).Copy _
Destination:=Sheets("Prelim Sort").Range("A1")
Thanks.