Break apart in long excel spreed sheet

G

Guest

I have one excel spread sheet like this on ColumnA like this
000
001
002
003
004
005
..
..
..
all the way done real long Column A
I would like to break down every 16 rows, so the
A1 will show000
A16 will show 001
A32 will show 002
A48 will show.003
so on and so for, until to the end of row

Thanks.

Lillian
 
G

Guest

Lillian:

try it,

r = Range("A65536").End(xlUp).Row
For i = r To 2 Step -1
Rows(i & ":" & i + 15).Insert Shift:=xlDown
Next
 
R

Rowan Drummond

SAVE your data first then try:

Sub mvdata()
Dim theData As Variant
Dim i As Long
theData = Range("A1:A" & Cells(Rows.Count, 1).End(xlUp).Row)
If UBound(theData) < 4098 Then
Columns(1).ClearContents
Columns(1).NumberFormat = "@"
Range("A1").Value = theData(1, 1)
For i = 2 To UBound(theData)
Cells((i * 16) - 16, 1).Value = theData(i, 1)
Next i
Else
MsgBox "Too much data"
End If
End Sub

Hope this helps
Rowan
 
G

Guest

Thanks It work, what is mean by " r To 2 Step -1" and "Rows(i & ":" & i +
15).Insert Shift:=xlDown"

Can you explain to me, I will be really appreciate it.
 

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