Solved

EXCEL VBA 500 points!!

Posted on 2009-04-06
2
144 Views
Last Modified: 2012-05-06
I have a spreadsheet with 150 rows of data.

I want to make another spreadsheet and couple each one of those rows 100 times one after another in the same order in the new spreadsheet.

 So in the new spreadhsheet there would 1500 rows total, 100same rows for each row in the original spreadhseet.

Is there a vba that does that?  thanks
0
Comment
Question by:GlobaLevel
2 Comments
 
LVL 1

Accepted Solution

by:
ZekeLA earned 500 total points
ID: 24079834
I suggest you just turn on macro recording, do the copy and paste a few times and then build your vba from that. I just tried it with a new spread sheet and got this as a start:

    Rows("1:8").Select
    Selection.Copy
    Range("A9").Select
    ActiveSheet.Paste
    Selection.End(xlDown).Select
    Range("A17").Select
    ActiveSheet.Paste
    Selection.End(xlDown).Select
    Range("A25").Select
    ActiveSheet.Paste
    Selection.End(xlDown).Select
    Range("A33").Select
    ActiveSheet.Paste

Basically, select the data you want to copy. Find the end of the data so far, go one more row and paste the selection there. Then just repeat the process of Find End and Past (no need to reselect the data to copy, it's still selected.)
0
 
LVL 10

Author Closing Comment

by:GlobaLevel
ID: 31567144
Awesome!
0

Featured Post

Does Powershell have you tied up in knots?

Managing Active Directory does not always have to be complicated.  If you are spending more time trying instead of doing, then it's time to look at something else. For nearly 20 years, AD admins around the world have used one tool for day-to-day AD management: Hyena. Discover why

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction I needed to skip over some file processing within a For...Next loop in some old production code and wished that VB (classic) had a statement that would drop down to the end of the current iteration, bypassing the statements that were c…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

821 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question