Brock_Hardchest
New Member
- Joined
- Feb 23, 2018
- Messages
- 27
Hello,
I am using a for loop to move some rows around. The loop skips rows as if it is stepping by 2. I have "Step 1" added and yet it still skips rows. Any ideas?
I am using a for loop to move some rows around. The loop skips rows as if it is stepping by 2. I have "Step 1" added and yet it still skips rows. Any ideas?
VBA Code:
j = 2
For i = 2 To row1 Step 1
If Range("R" & i) < 0 And Range("W" & i) < 0 Then
Sheets("Credit & Rebills Data").Range("A" & j).EntireRow.Value = Sheets("Current Invoice Query").Range("A" & i).EntireRow.Value
Sheets("Current Invoice Query").Range("A" & i).EntireRow.Delete
j = j + 1
End If
Next i