Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have a worksheet with over 1100 rows, but with data only in every
few rows. The other rows are "empty" (ISBLANK is true). I need a macro to delete the empty rows. Using Record Macro, I see that if I select a row and right-click Delete, the logic is: Rows("2:2").Select Selection.Delete shift:=xlUp So in my ignorance, I tried the following, to no avail: Dim cell As Range For Each cell In Range("1:1144") If cell = "" Then cell.Rows.Delete shift:=xlUp End If Next So how can I do this? PS: Also, I forgot how to turn off/on the worksheet update. And if I need to do this iteratively, as above, I would like to go from the bottom up so that the shift xlUp is more efficient. Many thanks. |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Delete Empty Rows Macro | Excel Programming | |||
Delete empty rows with macro by John Walkenbach | Excel Programming | |||
Delete Rows with Empty Cells with empty column 1 | Excel Programming | |||
How do I write a macro to delete all rows from the first empty ro. | Excel Programming | |||
Cut and Paste macro based on criteria then delete empty rows | Excel Programming |