Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.newusers
haystack
 
Posts: n/a
Default adding rows to excel table

I have created an inventory table with about 500 rows (one per item). Now, I
need to add five blank rows after each already entered row. These 5 new rows
contain a formula that is constant throughout the whole thing. Is there a
way to do this without manually adding them one by one? can't i just create
one set of the new rows including the formula and tell the program to insert
it after each existing row?
  #2   Report Post  
Posted to microsoft.public.excel.newusers
mudraker
 
Posts: n/a
Default adding rows to excel table


haystack

here is a macro that will insert 5 blank lines after every row

something similar can be done to insert formulas as required or to copy
a range and paste it into the blank rows


--
mudraker
------------------------------------------------------------------------
mudraker's Profile: http://www.excelforum.com/member.php...fo&userid=2473
View this thread: http://www.excelforum.com/showthread...hreadid=535761

  #3   Report Post  
Posted to microsoft.public.excel.newusers
mudraker
 
Posts: n/a
Default adding rows to excel table


haystack

Looks like I had a hiccup with my previous post as the code did not
show up

here is a macro that will insert 5 blank lines after every row

something similar can be done to insert formulas as required or to copy
a range and paste it into the blank rows


Sub InsertRows()
Dim lRow As Long
For lRow = Cells(Rows.Count, "a").End(xlUp).Row To 2 Step -1
Rows(lRow & ":" & lRow + 4).Insert Shift:=xlDown
Next lRow
End Sub


--
mudraker
------------------------------------------------------------------------
mudraker's Profile: http://www.excelforum.com/member.php...fo&userid=2473
View this thread: http://www.excelforum.com/showthread...hreadid=535761

  #4   Report Post  
Posted to microsoft.public.excel.newusers
mudraker
 
Posts: n/a
Default adding rows to excel table


haystack

Looks like I had a hiccup with my previous post as the code did not
show up

here is a macro that will insert 5 blank lines after every row

something similar can be done to insert formulas as required or to copy
a range and paste it into the blank rows


Sub InsertRows()
Dim lRow As Long
For lRow = Cells(Rows.Count, "a").End(xlUp).Row To 2 Step -1
Rows(lRow & ":" & lRow + 4).Insert Shift:=xlDown
Next lRow
End Sub


--
mudraker
------------------------------------------------------------------------
mudraker's Profile: http://www.excelforum.com/member.php...fo&userid=2473
View this thread: http://www.excelforum.com/showthread...hreadid=535761

  #5   Report Post  
Posted to microsoft.public.excel.newusers
mudraker
 
Posts: n/a
Default adding rows to excel table


haystack

Looks like I had a hiccup with my previous post as the code did not
show up

here is a macro that will insert 5 blank lines after every row

something similar can be done to insert formulas as required or to copy
a range and paste it into the blank rows


Sub InsertRows()
Dim lRow As Long
For lRow = Cells(Rows.Count, "a").End(xlUp).Row To 2 Step -1
Rows(lRow & ":" & lRow + 4).Insert Shift:=xlDown
Next lRow
End Sub


--
mudraker
------------------------------------------------------------------------
mudraker's Profile: http://www.excelforum.com/member.php...fo&userid=2473
View this thread: http://www.excelforum.com/showthread...hreadid=535761

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
print area selection slows excel, formula for hiding rows?? sbrimley Excel Discussion (Misc queries) 1 March 21st 06 11:26 PM
adding images to excel table automatically Grafula Excel Discussion (Misc queries) 1 March 14th 06 08:33 AM
consolidation of tables in excel with text and figures samenvoegen van sheets Excel Worksheet Functions 8 March 2nd 06 03:27 PM
Select all subtotal rows on Pivot Table Marcotte A Excel Worksheet Functions 2 February 23rd 06 06:10 PM
Pasting Word table cell with paragraph markers into single Excel c Steve Excel Discussion (Misc queries) 1 June 16th 05 11:26 PM


All times are GMT +1. The time now is 04:52 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"