Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default Copy and insert multipel rows after each row of data

I need to copy a row and insert it 19 times in the rows below it, for 100+
rows.
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 22,906
Default Copy and insert multipel rows after each row of data

You have 100+ rows.

One column or many columns of data?

Each row is to be duplicated 19 times for a total of 1900+ rows when
complete?

You want to do this manually or by code?


Gord Dibben MS Excel MVP

On Thu, 3 Jun 2010 15:36:44 -0700, myork
wrote:

I need to copy a row and insert it 19 times in the rows below it, for 100+
rows.


  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,520
Default Copy and insert multipel rows after each row of data

Try the below macro..

Sub MyMacro()
Dim lngRow As Long
lngRow = 1
Do While Range("A" & lngRow) < ""
Rows(lngRow).Offset(1).Resize(19).Insert
Rows(lngRow).Copy Rows(lngRow + 1 & ":" & lngRow + 19)
lngRow = lngRow + 20
Loop
End Sub

--
Jacob (MVP - Excel)


"myork" wrote:

I need to copy a row and insert it 19 times in the rows below it, for 100+
rows.

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
Automatically insert rows/copy formula JStiehl Excel Worksheet Functions 1 April 19th 10 01:55 PM
Insert rows and copy forumla above it Lisa[_3_] Excel Discussion (Misc queries) 3 November 7th 08 10:31 PM
Copy/Insert rows Niniel Excel Discussion (Misc queries) 2 August 31st 07 10:28 PM
How to insert rows that copy cell content of the row above Rocket Scientist Excel Discussion (Misc queries) 0 July 1st 07 04:18 PM
Copy/Insert rows with formulas GregR Excel Worksheet Functions 4 April 26th 05 10:29 PM


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

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"