Obrigado Alexandre e Reinaldo!
Não consegui resultados bons com as últimas indicações, porem utilizei algumas partes para incrementar o código original e ficou assim:
Sub NovaVersao()
Dim LR As Long
Rows(6).Resize(100).Delete
If Range("a2") <> "" And Range("b2") = "" And Range("c2") = "" And Range("d2") = "" And Range("e2") = "" Then fjpVBA = 1
If Range("a2") = "" And Range("b2") <> "" And Range("c2") = "" And Range("d2") = "" And Range("e2") = "" Then fjpVBA = 2
If Range("a2") = "" And Range("b2") = "" And Range("c2") <> "" And Range("d2") = "" And Range("e2") = "" Then fjpVBA = 3
If Range("a2") = "" And Range("b2") = "" And Range("c2") = "" And Range("d2") <> "" And Range("e2") = "" Then fjpVBA = 4
If Range("a2") = "" And Range("b2") = "" And Range("c2") = "" And Range("d2") = "" And Range("e2") <> "" Then fjpVBA = 5
If Range("a2") <> "" And Range("b2") <> "" And Range("c2") = "" And Range("d2") = "" And Range("e2") = "" Then fjpVBA = 6
If Range("a2") <> "" And Range("b2") = "" And Range("c2") <> "" And Range("d2") = "" And Range("e2") = "" Then fjpVBA = 7
If Range("a2") <> "" And Range("b2") = "" And Range("c2") = "" And Range("d2") <> "" And Range("e2") = "" Then fjpVBA = 8
If Range("a2") <> "" And Range("b2") = "" And Range("c2") = "" And Range("d2") = "" And Range("e2") <> "" Then fjpVBA = 9
If Range("a2") = "" And Range("b2") <> "" And Range("c2") <> "" And Range("d2") = "" And Range("e2") = "" Then fjpVBA = 10
If Range("a2") = "" And Range("b2") <> "" And Range("c2") = "" And Range("d2") <> "" And Range("e2") = "" Then fjpVBA = 11
If Range("a2") = "" And Range("b2") <> "" And Range("c2") = "" And Range("d2") = "" And Range("e2") <> "" Then fjpVBA = 12
If Range("a2") = "" And Range("b2") = "" And Range("c2") <> "" And Range("d2") <> "" And Range("e2") = "" Then fjpVBA = 13
If Range("a2") = "" And Range("b2") = "" And Range("c2") <> "" And Range("d2") = "" And Range("e2") <> "" Then fjpVBA = 14
If Range("a2") = "" And Range("b2") = "" And Range("c2") = "" And Range("d2") <> "" And Range("e2") <> "" Then fjpVBA = 15
If Range("a2") <> "" And Range("b2") <> "" And Range("c2") <> "" And Range("d2") = "" And Range("e2") = "" Then fjpVBA = 16
If Range("a2") <> "" And Range("b2") <> "" And Range("c2") = "" And Range("d2") <> "" And Range("e2") = "" Then fjpVBA = 17
If Range("a2") <> "" And Range("b2") <> "" And Range("c2") = "" And Range("d2") = "" And Range("e2") <> "" Then fjpVBA = 18
If Range("a2") <> "" And Range("b2") = "" And Range("c2") <> "" And Range("d2") <> "" And Range("e2") = "" Then fjpVBA = 19
If Range("a2") <> "" And Range("b2") = "" And Range("c2") <> "" And Range("d2") = "" And Range("e2") <> "" Then fjpVBA = 20
If Range("a2") <> "" And Range("b2") = "" And Range("c2") = "" And Range("d2") <> "" And Range("e2") <> "" Then fjpVBA = 21
If Range("a2") = "" And Range("b2") <> "" And Range("c2") <> "" And Range("d2") <> "" And Range("e2") = "" Then fjpVBA = 22
If Range("a2") = "" And Range("b2") <> "" And Range("c2") <> "" And Range("d2") = "" And Range("e2") <> "" Then fjpVBA = 23
If Range("a2") = "" And Range("b2") <> "" And Range("c2") = "" And Range("d2") <> "" And Range("e2") <> "" Then fjpVBA = 24
If Range("a2") = "" And Range("b2") = "" And Range("c2") <> "" And Range("d2") <> "" And Range("e2") <> "" Then fjpVBA = 25
If Range("a2") <> "" And Range("b2") <> "" And Range("c2") <> "" And Range("d2") <> "" And Range("e2") = "" Then fjpVBA = 26
If Range("a2") <> "" And Range("b2") <> "" And Range("c2") <> "" And Range("d2") = "" And Range("e2") <> "" Then fjpVBA = 27
If Range("a2") <> "" And Range("b2") <> "" And Range("c2") = "" And Range("d2") <> "" And Range("e2") <> "" Then fjpVBA = 28
If Range("a2") <> "" And Range("b2") = "" And Range("c2") <> "" And Range("d2") <> "" And Range("e2") <> "" Then fjpVBA = 29
If Range("a2") = "" And Range("b2") <> "" And Range("c2") <> "" And Range("d2") <> "" And Range("e2") <> "" Then fjpVBA = 30
If Range("a2") <> "" And Range("b2") <> "" And Range("c2") <> "" And Range("d2") <> "" And Range("e2") <> "" Then fjpVBA = 31
Select Case fjpVBA
Case 1
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=1, Criteria1:=Range("a2")
.Copy Range("a6")
.AutoFilter
End With
Case 2
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=4, Criteria1:=Range("b2")
.Copy Range("a6")
.AutoFilter
End With
Case 3
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=8, Criteria1:=Range("c2")
.Copy Range("a6")
.AutoFilter
End With
Case 4
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=21, Criteria1:=Range("d2")
.Copy Range("a6")
.AutoFilter
End With
Case 5
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=24, Criteria1:=">=" & Format(Range("e2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat), Operator:=xlAnd, Criteria2:="<=" & Format(Range("f2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat)
.Copy Range("a6")
.AutoFilter
End With
Case 6
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=1, Criteria1:=Range("a2")
.AutoFilter Field:=4, Criteria1:=Range("b2")
.Copy Range("a6")
.AutoFilter
End With
Case 7
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=1, Criteria1:=Range("a2")
.AutoFilter Field:=8, Criteria1:=Range("c2")
.Copy Range("a6")
.AutoFilter
End With
Case 8
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=1, Criteria1:=Range("a2")
.AutoFilter Field:=21, Criteria1:=Range("d2")
.Copy Range("a6")
.AutoFilter
End With
Case 9
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=1, Criteria1:=Range("a2")
.AutoFilter Field:=24, Criteria1:=">=" & Format(Range("e2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat), Operator:=xlAnd, Criteria2:="<=" & Format(Range("f2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat)
.Copy Range("a6")
.AutoFilter
End With
Case 10
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=4, Criteria1:=Range("b2")
.AutoFilter Field:=8, Criteria1:=Range("c2")
.Copy Range("a6")
.AutoFilter
End With
Case 11
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=4, Criteria1:=Range("b2")
.AutoFilter Field:=21, Criteria1:=Range("d2")
.Copy Range("a6")
.AutoFilter
End With
Case 12
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=4, Criteria1:=Range("b2")
.AutoFilter Field:=24, Criteria1:=">=" & Format(Range("e2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat), Operator:=xlAnd, Criteria2:="<=" & Format(Range("f2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat)
.Copy Range("a6")
.AutoFilter
End With
Case 13
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=8, Criteria1:=Range("c2")
.AutoFilter Field:=21, Criteria1:=Range("d2")
.Copy Range("a6")
.AutoFilter
End With
Case 14
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=8, Criteria1:=Range("c2")
.AutoFilter Field:=24, Criteria1:=">=" & Format(Range("e2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat), Operator:=xlAnd, Criteria2:="<=" & Format(Range("f2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat)
.Copy Range("a6")
.AutoFilter
End With
Case 15
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=21, Criteria1:=Range("d2")
.AutoFilter Field:=24, Criteria1:=">=" & Format(Range("e2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat), Operator:=xlAnd, Criteria2:="<=" & Format(Range("f2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat)
.Copy Range("a6")
.AutoFilter
End With
Case 16
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=1, Criteria1:=Range("a2")
.AutoFilter Field:=4, Criteria1:=Range("b2")
.AutoFilter Field:=8, Criteria1:=Range("c2")
.Copy Range("a6")
.AutoFilter
End With
Case 17
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=1, Criteria1:=Range("a2")
.AutoFilter Field:=4, Criteria1:=Range("b2")
.AutoFilter Field:=21, Criteria1:=Range("d2")
.Copy Range("a6")
.AutoFilter
End With
Case 18
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=1, Criteria1:=Range("a2")
.AutoFilter Field:=4, Criteria1:=Range("b2")
.AutoFilter Field:=24, Criteria1:=">=" & Format(Range("e2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat), Operator:=xlAnd, Criteria2:="<=" & Format(Range("f2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat)
.Copy Range("a6")
.AutoFilter
End With
Case 19
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=1, Criteria1:=Range("a2")
.AutoFilter Field:=8, Criteria1:=Range("c2")
.AutoFilter Field:=21, Criteria1:=Range("d2")
.Copy Range("a6")
.AutoFilter
End With
Case 20
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=1, Criteria1:=Range("a2")
.AutoFilter Field:=8, Criteria1:=Range("c2")
.AutoFilter Field:=24, Criteria1:=">=" & Format(Range("e2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat), Operator:=xlAnd, Criteria2:="<=" & Format(Range("f2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat)
.Copy Range("a6")
.AutoFilter
End With
Case 21
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=1, Criteria1:=Range("a2")
.AutoFilter Field:=21, Criteria1:=Range("d2")
.AutoFilter Field:=24, Criteria1:=">=" & Format(Range("e2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat), Operator:=xlAnd, Criteria2:="<=" & Format(Range("f2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat)
.Copy Range("a6")
.AutoFilter
End With
Case 22
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=4, Criteria1:=Range("b2")
.AutoFilter Field:=8, Criteria1:=Range("c2")
.AutoFilter Field:=21, Criteria1:=Range("d2")
.Copy Range("a6")
.AutoFilter
End With
Case 23
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=4, Criteria1:=Range("b2")
.AutoFilter Field:=8, Criteria1:=Range("c2")
.AutoFilter Field:=24, Criteria1:=">=" & Format(Range("e2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat), Operator:=xlAnd, Criteria2:="<=" & Format(Range("f2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat)
.Copy Range("a6")
.AutoFilter
End With
Case 24
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=4, Criteria1:=Range("b2")
.AutoFilter Field:=21, Criteria1:=Range("d2")
.AutoFilter Field:=24, Criteria1:=">=" & Format(Range("e2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat), Operator:=xlAnd, Criteria2:="<=" & Format(Range("f2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat)
.Copy Range("a6")
.AutoFilter
End With
Case 25
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=8, Criteria1:=Range("c2")
.AutoFilter Field:=21, Criteria1:=Range("d2")
.AutoFilter Field:=24, Criteria1:=">=" & Format(Range("e2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat), Operator:=xlAnd, Criteria2:="<=" & Format(Range("f2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat)
.Copy Range("a6")
.AutoFilter
End With
Case 26
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=1, Criteria1:=Range("a2")
.AutoFilter Field:=4, Criteria1:=Range("b2")
.AutoFilter Field:=8, Criteria1:=Range("c2")
.AutoFilter Field:=21, Criteria1:=Range("d2")
.Copy Range("a6")
.AutoFilter
End With
Case 27
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=1, Criteria1:=Range("a2")
.AutoFilter Field:=4, Criteria1:=Range("b2")
.AutoFilter Field:=8, Criteria1:=Range("c2")
.AutoFilter Field:=24, Criteria1:=">=" & Format(Range("e2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat), Operator:=xlAnd, Criteria2:="<=" & Format(Range("f2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat)
.Copy Range("a6")
.AutoFilter
End With
Case 28
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=1, Criteria1:=Range("a2")
.AutoFilter Field:=4, Criteria1:=Range("b2")
.AutoFilter Field:=21, Criteria1:=Range("d2")
.AutoFilter Field:=24, Criteria1:=">=" & Format(Range("e2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat), Operator:=xlAnd, Criteria2:="<=" & Format(Range("f2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat)
.Copy Range("a6")
.AutoFilter
End With
Case 29
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=1, Criteria1:=Range("a2")
.AutoFilter Field:=8, Criteria1:=Range("c2")
.AutoFilter Field:=21, Criteria1:=Range("d2")
.AutoFilter Field:=24, Criteria1:=">=" & Format(Range("e2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat), Operator:=xlAnd, Criteria2:="<=" & Format(Range("f2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat)
.Copy Range("a6")
.AutoFilter
End With
Case 30
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=4, Criteria1:=Range("b2")
.AutoFilter Field:=8, Criteria1:=Range("c2")
.AutoFilter Field:=21, Criteria1:=Range("d2")
.AutoFilter Field:=24, Criteria1:=">=" & Format(Range("e2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat), Operator:=xlAnd, Criteria2:="<=" & Format(Range("f2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat)
.Copy Range("a6")
.AutoFilter
End With
Case Else
With Sheets("MOVCAIXA").UsedRange
.AutoFilter Field:=1, Criteria1:=Range("a2")
.AutoFilter Field:=4, Criteria1:=Range("b2")
.AutoFilter Field:=8, Criteria1:=Range("c2")
.AutoFilter Field:=21, Criteria1:=Range("d2")
.AutoFilter Field:=24, Criteria1:=">=" & Format(Range("e2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat), Operator:=xlAnd, Criteria2:="<=" & Format(Range("f2").Value, Sheets("MOVCAIXA").Range("X2").NumberFormat)
.Copy Range("a6")
.AutoFilter
End With
End Select
End Sub
Percebi que se tento fazer uma pesquisa em cima de pesquisa a planilha busca dados errados, para contornar isso sempre tenho que clicar em "Limpar" para recomeçar a pesquisa, ai não da erro.
O código está OK?