I have the below code to transpose the first cell of each row onto a single row, but I'm not sure how to amend it so that it takes the first 5 cells of each row and does the same?
ie I have this data in rows A-E -
and the code will copy the dates in column A as below -
But what I would like is the data transposed as below and so on. It also creates a new worksheet to transpose onto, what I would ideally like is for it to copy to an existing sheet (for arguments sake Sheet1) -
Option Explicit
Sub Transpose_List()
Dim WS As Worksheet
Dim WSA As Worksheet
Dim NextRow As Long
Dim LastRow As Long
Dim i As Long
Set WSA = ActiveSheet
Set WS = ActiveWorkbook.Sheets.Add(Before:=Worksheets(Worksheets.Count))
WS.Name = "Transposed"
LastRow = WSA.Cells(Rows.Count, 1).End(xlUp).row
Application.ScreenUpdating = False
For i = 5 To LastRow Step 6
NextRow = WS.Cells(Rows.Count, 1).End(xlUp).row + 1
WSA.Cells(i, 1).Resize(6, 1).Copy
WS.Cells(NextRow, 1).PasteSpecial Transpose:=True
Next i
WS.Columns("A:F").AutoFit
Application.ScreenUpdating = True
End Sub



=TEXTSPLIT(TEXTJOIN(",",FALSE,A5:E10),",")Set WSto an existingworkbook/worksheetand remove the code that is creating the new sheet.