Hey!
I've seen this thread which seems to be what I'm after, but doesn't quite work for me...
https://www.mrexcel.com/forum/excel-questions/593812-macro-autofilter-skip-if-blank.html
When I use the answer here it skips even if there is a field present. Below is what I have, there are several filters in play it is just the last one which is the issue where it is text specific. This could be one of 8 variants but will not always be there based on the previous filters.
Any help greatly appreciated!
ActiveSheet.Range("$A$1:$V$3000").AutoFilter Field:=13, Criteria1:="Y"
ActiveSheet.Range("$A$1:$V$3000").AutoFilter Field:=15, Criteria1:="<=0", _
Operator:=xlAnd
ActiveSheet.Range("$A$1:$V$3000").AutoFilter Field:=14, Criteria1:=">0", _
Operator:=xlAnd
ActiveSheet.Range("$A$1:$V$3000").AutoFilter Field:=3, Criteria1:=">0", _
Operator:=xlAnd
ActiveSheet.Range("$A$1:$V$3000").AutoFilter Field:=10, Criteria1:="Dubai Air", _
Operator:=xlAnd
Range("B2:C3000").Select
Selection.Copy
Sheets("Sheet1").Select
Range("A2").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Sheets("Sheet1").Select
Application.CutCopyMode = False
Sheets("Sheet1").Copy
I've seen this thread which seems to be what I'm after, but doesn't quite work for me...
https://www.mrexcel.com/forum/excel-questions/593812-macro-autofilter-skip-if-blank.html
When I use the answer here it skips even if there is a field present. Below is what I have, there are several filters in play it is just the last one which is the issue where it is text specific. This could be one of 8 variants but will not always be there based on the previous filters.
Any help greatly appreciated!
ActiveSheet.Range("$A$1:$V$3000").AutoFilter Field:=13, Criteria1:="Y"
ActiveSheet.Range("$A$1:$V$3000").AutoFilter Field:=15, Criteria1:="<=0", _
Operator:=xlAnd
ActiveSheet.Range("$A$1:$V$3000").AutoFilter Field:=14, Criteria1:=">0", _
Operator:=xlAnd
ActiveSheet.Range("$A$1:$V$3000").AutoFilter Field:=3, Criteria1:=">0", _
Operator:=xlAnd
ActiveSheet.Range("$A$1:$V$3000").AutoFilter Field:=10, Criteria1:="Dubai Air", _
Operator:=xlAnd
Range("B2:C3000").Select
Selection.Copy
Sheets("Sheet1").Select
Range("A2").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Sheets("Sheet1").Select
Application.CutCopyMode = False
Sheets("Sheet1").Copy