I have a large data set consisting of two columns with repeat row names but unique row values. Here is a small example:
A 1
A 2
A 3
A 4
A 5
A 6
A 7
B 8
B 9
B 10
B 11
B 12
B 13
B 14
C 15
C 16
C 17
C 18
C 19
C 20
C 21
I would like to convert this to a few rows with multiple columns. Like this:
A 1 2 3 4 5 6 7
B 8 9 10 11 12 13 14
C 15 16 17 18 19 20 21
I tried to record a macro, but I could not figure out how to get the macro to not only select the range of cells from B1:B7 but also from B8:B14 when I click on B8. The macro always reverted to B1:7.
Here is my example macro:
Sub Macro2()
'
' Macro1 Macro
'
'
Range("B1:B7").Select
Selection.Copy
Range("D2").Select
Selection.PasteSpecial Paste:=xlPasteAll, Operation:=xlNone, SkipBlanks:= _
False, Transpose:=True
End Sub
Thank you for your help.
Bookmarks