Hi Alan
And what do you think of this?
Sub Delete()
For i = 9 To 119
For j = 3 To 3
If Cells(i, j) = "0" Or Cells(i, j) = "" Then
Rows(i).Delete
End If
Next j
Next i
End Sub
Hi Alan
And what do you think of this?
Sub Delete()
For i = 9 To 119
For j = 3 To 3
If Cells(i, j) = "0" Or Cells(i, j) = "" Then
Rows(i).Delete
End If
Next j
Next i
End Sub
Last edited by Raiby; 11-17-2006 at 01:48 PM.
Hi Raiby
Thanks for the code, I cannot get it to work.
Alan
Hi Alan
Did you see my correction?
DrumsforMonty, i'm no expert and my code worked for me but there is a flaw, as it looks from the top down if it comes across 2 blanks in a row it will only see them as one, so i posted my answer to another forum (full of experienced guys) and i got a lesson aswell as a couple of solutions here's the thread http://vbaexpress.com/forum/showthre...9882#post79882 MDmackillop probably has the solution closest to what you need.
Regards,
Simon
Hi Simon, thanks for that, I have joined that forum.
Hi Raiby
Sorry I didnt see a correction.
Alan
Hi Alan
In fact I forgot this piece of code:
Or Cells(i, j) = "" for the blanks
But i suppose that it doesn't change your problem.It's strange. The code works for me.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks