Hello everyone. I have a VBA code that I am using to filter data by using columns headers in the range A1 trough AU1. Specificaly column AI needs to be filtered with the criteria set to 3. Below is the code that I have come up with, and it errors out. Note that code does apply the filters, ait just does not filter down to the criteria. Any help on this would be greatly appreciated.
Sub FilterToL3()
Dim wb1 As Workbook
Dim sPath1 As String
Const sFileInp1 As String = "105_version1.xlsm"
sPath1 = fPath & fDate & "_157\105_Reports\"
Set wb1 = Workbooks.Open(sPath1 & sFileInp1)
With ActiveSheet
.AutoFilterMode = False
.Range("A1:AU1").AutoFilter
.Range("A1:AU1").AutoFilter Field:=35, Criteria1:=3
End With
End Sub
Bookmarks