I am trying to continue the process until the end of the cells, but the selection needs to change in a set order. Here's the code:
' C_P Macro
' copies from worksheet & pastes in new sheet
' Keyboard Shortcut: Ctrl+Shift+L
Dim rng1 As Range
Dim Look As String
Dim iRow As Integer
With Windows("Audubon-Crest-Rent-Roll-201502-1.xlsx").Activate
Set rng1 = Range("A:A")
ActiveCell = Range("A228")
Do
Windows("Audubon-Crest-Rent-Roll-201502-1.xlsx").Activate
Range("A228:A239").Select
Selection.Copy
Windows("Audubon Crest Rent Roll 20150219-altered.xlsm").Activate
Range("B17").Select
Selection.PasteSpecial Paste:=xlPasteAll, Operation:=xlNone, SkipBlanks:= _
False, Transpose:=True
Windows("Audubon-Crest-Rent-Roll-201502-1.xlsx").Activate
Application.CutCopyMode = False
Range("A228:A239").Offset(13, 0).Select
Selection.Copy
Windows("Audubon Crest Rent Roll 20150219-altered.xlsm").Activate
Range("B17").Offset(1, 0).Select
Selection.PasteSpecial Paste:=xlPasteAll, Operation:=xlNone, SkipBlanks:= _
False, Transpose:=True
Range("B18").Select
Loop Until IsEmpty(Cells(iRow, 1))
End With
End Sub
As you can see, what it basically does is Make a selection of 11 rows and then transpose copies the data into the next workbook at the next row. I F8'd through the procedure and I can tell that it works well for one selection then moves down 13 rows and does the next selection, BUT I'm not sure how to make it continuously move through the data. I need for it to always select 11 rows, do the procedure then count thirteen rows down and do it again until it hits an empty row. Ideally I could set it up to Find a certain cell entry and select 11 rows once it locates the next instance of this cell entry, but I think the 13 rows remains as a pattern so if it just counts down 13 rows that should be fine.
So, I think my quandary is how to make the row selections variable. When I look into the code I can see that my row selections are concrete values so if I were to run the Macro it wouldn't move down, it would just do the cells I have indicated. How can I make it move down through the cells?