S
seed
I borrowed this code from another post. Don't recall whose it was, but
thanks for it.
Anyway, I adapted it as well as I could to what I'm using it for and am
getting an error.
I've already set the dim obs as a value from a cell. I want this code to
delete all rows where column D does not equal 2*the value of obs. This may
be a really simple question.
Sub deleteotherobsnumber()
For i = Cells(Rows.Count, "d").End(xlUp).Row To 2 Step -1
If Cells(i, "d") <> obs * 2 Then Cells(i, "d").EntireRow.Delete
Next i
Range("D165536").Select
Selection.Delete
End Sub
thanks for it.
Anyway, I adapted it as well as I could to what I'm using it for and am
getting an error.
I've already set the dim obs as a value from a cell. I want this code to
delete all rows where column D does not equal 2*the value of obs. This may
be a really simple question.
Sub deleteotherobsnumber()
For i = Cells(Rows.Count, "d").End(xlUp).Row To 2 Step -1
If Cells(i, "d") <> obs * 2 Then Cells(i, "d").EntireRow.Delete
Next i
Range("D165536").Select
Selection.Delete
End Sub