In a posting 1998-05-17 to programming newsgroup, Dana DeLouis
points out that SpecialCells frequently provides a quick method of
eliminating loops, and because SpecialCells is limited to the
UsedRange it will not be wasting time looping through the end of a
worksheet. His Example:
On Error Resume Next ' In case there are no blanks
Columns("A:A").SpecialCells(xlCellTypeBlanks).EntireRow.Delete
ActiveSheet.UsedRange 'Resets UsedRange for Excel 97
more information about similar coding in
Delete Cells/Rows in Range, based on empty cells, or cells with specific valuesLocation:
http://www.mvps.org/dmcritchie/excel/delempty.htm
---
HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages:
http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page:
http://www.mvps.org/dmcritchie/excel/search.htm
Dave Peterson said:
J.E. McGimpsey just posted a reply in this thread:
http://google.com/groups?threadm=#[email protected]
delete the rows that aren't being used. (I'm thinking a simple macro testing if A36 is populated, if not delete row, if - then end.
decrement to A35... repeat until filled cell is found).