Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 390
Default Hpw do I delete multiple empty rows found between filled rows?

My data spreadsheet contains multiple empty rows found among thousands of
filled rows. Is there a way to delete the empty rows collectively without
having to do each one separately?
Thank you
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11,058
Default Hpw do I delete multiple empty rows found between filled rows?

Try this small macro:

Sub macro_der()
Dim i As Long, nLastRow As Long
Set r = ActiveSheet.UsedRange
nLastRow = r.Rows.Count + r.Row - 1
Set r = Rows(nLastRow + 1)
For i = 1 To nLastRow
If Application.CountA(Rows(i)) = 0 Then
Set r = Union(r, Rows(i))
End If
Next
r.Delete
End Sub
--
Gary''s Student - gsnu200908


"Bill" wrote:

My data spreadsheet contains multiple empty rows found among thousands of
filled rows. Is there a way to delete the empty rows collectively without
having to do each one separately?
Thank you

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 22,906
Default Hpw do I delete multiple empty rows found between filled rows?

Select a column.

F5SpecialBlanksOK

EditDeleteEntire Row


Gord Dibben MS Excel MVP

On Sat, 14 Nov 2009 16:31:01 -0800, Bill
wrote:

My data spreadsheet contains multiple empty rows found among thousands of
filled rows. Is there a way to delete the empty rows collectively without
having to do each one separately?
Thank you


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Count filled data rows until empty Dallman Ross Excel Discussion (Misc queries) 7 May 9th 23 11:43 AM
delete empty rows aditya Excel Discussion (Misc queries) 1 June 3rd 09 12:58 PM
How to Delete empty rows in excel in b/w rows with values Dennis Excel Worksheet Functions 3 August 28th 07 04:15 PM
Cut filtered rows, paste into next empty row of new sheet, and delete cut rows Scott Excel Worksheet Functions 0 December 13th 06 01:25 AM
delete empty rows between rows with text Paulo Baptista Excel Discussion (Misc queries) 2 February 28th 05 03:41 PM


All times are GMT +1. The time now is 11:06 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"