JoeyGaspard
Board Regular
- Joined
- Jul 22, 2019
- Messages
- 147
I am using the following code to filter and delete data, I would like to be able to copy the filtered data, but instead of the "EntireRow", I want to copy range A:E of the filtered set only instead of deleting, to cell A1 of another worksheet and turn off the filter so I can do it again with a different code, can someone help me on how to do that? Thanks in Advance!!
With Sheets("Data")
.AutoFilterMode = False
With .Range("A1", .Range("A" & Rows.Count).End(xlUp))
.AutoFilter 1, "95802"
On Error Resume Next
.Offset(1).SpecialCells(12).EntireRow.Delete
End With
.AutoFilterMode = False
End With
With Sheets("Data")
.AutoFilterMode = False
With .Range("A1", .Range("A" & Rows.Count).End(xlUp))
.AutoFilter 1, "95802"
On Error Resume Next
.Offset(1).SpecialCells(12).EntireRow.Delete
End With
.AutoFilterMode = False
End With