Hello all,
I have this code that does what it's supposed to, but it requires me to run the code several times, I am just trying to see what I can improve upon to make this code run completely the first time.
many thanks!
I have this code that does what it's supposed to, but it requires me to run the code several times, I am just trying to see what I can improve upon to make this code run completely the first time.
VBA Code:
Sub deleteNonBank()
Dim R As Long
Dim Lastrow As Long
Lastrow = ActiveSheet.Range("A" & Rows.Count).End(xlUp).Row
'Columns("A:A").Select
For R = 2 To Lastrow
If Range("A" & R).Value <> "89" Then Rows(R).Delete
Next R
End Sub
many thanks!