Home |
Search |
Today's Posts |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Janis,
It seems like you missed a "." So, replace this line Columns("M").SpecialCells(xlCellTypeBlanks).Entire Row.Delete With this .Columns("M").SpecialCells(xlCellTypeBlanks).Entir eRow.Delete -- Hope that helps. Vergel Adriano "Janis" wrote: When I run this script from either the workbook where the worksheet is located or from my personal.xls workbook it does not delete the rows that have blank cells in column ("M"). It doesn't seem to do anything. It compiles but it doesn't run. I still have all the rows with blank cells in column "M" which are not needed for this report. thanks, Sub DeleteRows() With ActiveSheet On Error Resume Next Columns("M").SpecialCells(xlCellTypeBlanks).Entire Row.Delete On Error GoTo 0 End With End Sub |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Delete blank rows | Excel Discussion (Misc queries) | |||
How do I delete blank rows (rows alternate data, blank, data, etc | Excel Discussion (Misc queries) | |||
need macro script - repeat to delete 2 rows | Excel Discussion (Misc queries) | |||
Delete Blank rows | Excel Programming | |||
Delete blank row only if 2 consecutive blank rows | Excel Programming |