Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Macro to delete blank rows in a worksheet
I am attempting to create a macro that will eliminate blank rows from a tab
in a worksheet. I need to do this in order to maintain the "auto-complete" functionality. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Macro to delete blank rows in a worksheet
Hi,
Right click your sheet tab, view code and paste this in and run it Sub Sonic() Dim i As Long With Application .Calculation = xlCalculationManual .ScreenUpdating = False lastrow = Cells(Rows.Count, "A").End(xlUp).Row For i = lastrow To 1 Step -1 If WorksheetFunction.CountA(Rows(i)) = 0 Then Rows(i).EntireRow.Delete End If Next i .Calculation = xlCalculationAutomatic .ScreenUpdating = True End With End Sub Mike "adchris" wrote: I am attempting to create a macro that will eliminate blank rows from a tab in a worksheet. I need to do this in order to maintain the "auto-complete" functionality. |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Macro to delete blank rows in a worksheet
Do you need a macro?
Select a column with the blank rows and F5SpecialBlanksOK EditDeleteEntire Row. Gord Dibben MS Excel MVP On Fri, 20 Mar 2009 13:44:01 -0700, adchris wrote: I am attempting to create a macro that will eliminate blank rows from a tab in a worksheet. I need to do this in order to maintain the "auto-complete" functionality. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Delete ANY blank rows on worksheet | Excel Discussion (Misc queries) | |||
Delete blank rows Macro | Excel Discussion (Misc queries) | |||
Using a macro to delete all blank rows | Excel Programming | |||
Macro to delete blank rows | Excel Programming | |||
Macro to delete blank rows | Excel Programming |