I want to filter a column, then add the filtered values.
Here is my code to filter:
It works fine.
Here is my code to add:
for some reason it is still ading the column without the filter (includes everything in that column)
How can I filter the column then add just the filtered values?
Here is my code to filter:
Code:
Range("D1").Select
Selection.AutoFilter
ActiveSheet.Range("$C:$D").AutoFilter Field:=2, Criteria1:="SI"
Here is my code to add:
Code:
[B][COLOR=#ff0000]Set [/COLOR][/B]myRange = ActiveSheet.Range("H2", Range("H2").End(xlDown))
Range("AM1") = WorksheetFunction.Sum(myRange)
for some reason it is still ading the column without the filter (includes everything in that column)
How can I filter the column then add just the filtered values?