View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
joel joel is offline
external usenet poster
 
Posts: 9,101
Default Complex copy and paste in excel

Sub MoveStates()

With Sheets("Sheet1")
OldRow = 1
NewRow = 1
Do While .Range("A" & OldRow) < ""
.Range("A" & OldRow).Copy _
Destination:=Sheets("sheet2").Range("A" & NewRow)

OldRow = OldRow + 1
NewRow = NewRow + 6
Loop

End With

End Sub


" wrote:

Hello, I have a spreadsheet that has the listings of all the 50 states
in Column A. But, I would like to copy each state in a different
spreadsheet with 6 columns apart. For example.

State
Alabama
Alaska
Arizona

This is what I would like to see
State
Alabama
-
-
-
-
-
-
Alaska
-
-
-
-
-
-
Arizona