Godders199
Active Member
- Joined
- Mar 2, 2017
- Messages
- 313
- Office Version
- 2013
Hello, I have written the following code to delete all rows where the cell in column J is Blank, but currently it is deleting all rows
Dim uLastRow As Long
Dim u As Long
uLastRow = Cells(Rows.Count, "d").End(xlUp).Row
For u = uLastRow To 1 Step -1
If Cells(u, "j").Value = "" Then
Rows(u).Delete
End If
Next u
I do have column A hidden, but even unhiding that has the same result. is there any reason why it is deleting all rows?
Dim uLastRow As Long
Dim u As Long
uLastRow = Cells(Rows.Count, "d").End(xlUp).Row
For u = uLastRow To 1 Step -1
If Cells(u, "j").Value = "" Then
Rows(u).Delete
End If
Next u
I do have column A hidden, but even unhiding that has the same result. is there any reason why it is deleting all rows?