Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default How can I insert a blank row after every four rows in Excel?

I have a large file (1,000+ rows) and I need to insert a blank row after
every four rows. Is there an easy way to do this without having to manually
insert each row?

Thank you.
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,942
Default How can I insert a blank row after every four rows in Excel?

hi,
here is something that might help. paste this code in a standard module and
run it.
Sub Macro1()

Dim r1 As Range
Dim r2 As Range

Range("A6").Select
Set r1 = Range("A6") 'assuming you have a header row
Do While Not IsEmpty(r1)
Set r2 = r1.Offset(4, 0)
ActiveCell.EntireRow.Insert
r1.Offset(4, 0).Select
Set r1 = r2
Loop

End Sub

regards
FSt1

"EmmaSB" wrote:

I have a large file (1,000+ rows) and I need to insert a blank row after
every four rows. Is there an easy way to do this without having to manually
insert each row?

Thank you.

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 281
Default How can I insert a blank row after every four rows in Excel?

Hi,

Try this with using a helper column:

in the first row of your data in helper column enter 1 and in the second row
enter 2 and then highlight the numbers 1 & 2 copy drag to last row of your
data you see a number in the last row of your data in helper column e.g:
1300, then enter 5 inthe row after that number and 9 in the next row
highlight 5 & 9 and copy darg down to whenever you see the number 1300
lighlight all yur data with the blank rows with numbers and then sort
highlighted area based on the helper column.

example:

A B C D

1 data data data 1
2 data data data 2
3 data data data 3
.. data data data .
.. data data data .
1300 data data data 1300
1301 BLANK ROWS 5
1302 BLANK ROWS 9
1303 BLANK ROWS 13
.. BLANK ROWS .
.. 1300

you can highlight all tese datas and blank rows and the sort it based on
column D

it should work.

Thanks,


--
Farhad Hodjat


"EmmaSB" wrote:

I have a large file (1,000+ rows) and I need to insert a blank row after
every four rows. Is there an easy way to do this without having to manually
insert each row?

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
'Insert' 'Object' command: I have 11 blank rows of objects at top normally pretty pc savvy... Excel Discussion (Misc queries) 0 November 4th 06 05:59 AM
How do I insert blank rows between rows in completed worksheet? bblue1978 Excel Discussion (Misc queries) 1 October 26th 06 07:02 PM
automatically insert 8 blank rows between each record Evad Excel Discussion (Misc queries) 1 February 2nd 06 04:35 AM
Insert blank rows repeatedly between every data row in Excel Cool Excel Discussion (Misc queries) 2 January 9th 06 12:10 PM
How to quickly insert a blank row every 5 rows? Med Excel Discussion (Misc queries) 2 September 10th 05 12:32 AM


All times are GMT +1. The time now is 09:46 AM.

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

About Us

"It's about Microsoft Excel"