T
transferxxx
My macro below is not working properly:
Sub Deletedepo()
With ActiveSheet
..DisplayPageBreaks = False
StartRow = 1
EndRow = .Cells(.Rows.Count, "C").End(xlUp).Row
For Lrow = EndRow To StartRow Step -1
If .Cells(Lrow, "C").Value = "CASH DEPOSIT *" Then
..Rows(Lrow).Delete
End If
Next
End With
End Sub
I would like to delete all rows with cells in column c containing e.g
Cash deposit GBP1000
Cash deposit Euro 50
But the wild card * is not working - can someone pls correct my macro
Thxs
Sub Deletedepo()
With ActiveSheet
..DisplayPageBreaks = False
StartRow = 1
EndRow = .Cells(.Rows.Count, "C").End(xlUp).Row
For Lrow = EndRow To StartRow Step -1
If .Cells(Lrow, "C").Value = "CASH DEPOSIT *" Then
..Rows(Lrow).Delete
End If
Next
End With
End Sub
I would like to delete all rows with cells in column c containing e.g
Cash deposit GBP1000
Cash deposit Euro 50
But the wild card * is not working - can someone pls correct my macro
Thxs