run blah while the source sheet is the active sheet.
Code:
Sub blah()
D
Range(Range("B1"), Range("B1").End(xlToRight)).Copy
'Range("B1:MZ1").copy
Sheets.Add After:=Sheets(Sheets.Count)
Selection.PasteSpecial Transpose:=True
D2
Range(Range("B1:B12"), Range("B1:B12").End(xlToRight)).Copy
'Range("B1:AF12").copy
Sheets.Add After:=Sheets(Sheets.Count)
Selection.PasteSpecial Transpose:=True
End Sub
Sub D()
Dim X As Long, LastRow As Long, vArrIn As Variant, vArrOut As Variant
LastRow = Cells(Rows.Count, "A").End(xlUp).Row
vArrIn = Range("A1:A" & LastRow)
ReDim vArrOut(1 To 60, 1 To Int(LastRow / 60) + 1)
For X = 0 To LastRow - 1
vArrOut(1 + (X Mod 60), 1 + Int(X / 60)) = vArrIn(X + 1, 1)
Next
Range("B1").Resize(60, UBound(vArrOut, 2)) = vArrOut
End Sub
Sub D2()
Dim X As Long, LastRow As Long, vArrIn As Variant, vArrOut As Variant
LastRow = Cells(Rows.Count, "A").End(xlUp).Row
vArrIn = Range("A1:A" & LastRow)
ReDim vArrOut(1 To 12, 1 To Int(LastRow / 12) + 1)
For X = 0 To LastRow - 1
vArrOut(1 + (X Mod 12), 1 + Int(X / 12)) = vArrIn(X + 1, 1) * 100
Next
With Range("B1").Resize(12, UBound(vArrOut, 2))
.Value = vArrOut
.NumberFormat = "0"
End With
End Sub
https://www.youtube.com/channel/UCnxwq2aGJRbjOo_MO54oaHA
Bookmarks