copy text A1*7

G

gustav

Hi

I want to copy the text in cell A1 3 times, and the text in cell A2 3
times, below each other.
This should be as shown below, need to be used when you have over 100
names.
It is time consuming to do this manually.

name1
name2
name3
name4
name5
name6

name1
name1
name1
name2
name2
name2 and so on.

Greteful for anykind of help
Tomas Fredblad
 
B

Bob Phillips

Sub Test()
Dim iLastRow As Long
Dim i As Long

iLastRow = Cells(Rows.Count, "A").End(xlUp).Row
For i = iLastRow To 1 Step -1
Rows(i + 1).Resize(2).Insert
Cells(i, "A").Copy Cells(i + 1, "A").Resize(2)
Next i

End Sub

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)
 
G

Guest

In an empty column, enter this formula and copy it down

=OFFSET($A$1,INT((ROW(A1)-1)/3),0)

then select all the formula results, copy them, and use Edit>Paste
Special>Values
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top