How to convert this :
FROM
X1 A1
X1 A2
X1 A3
X1 A4
X1 A5
X1 A6
X1 A7
X1 A8
X2 A9
X2 A10
X2 A11
X2 A12
X2 A13
X2 A14
X2 A15
X2 A16
TO
X1 A1 A2 A3 A4
X1 A5 A6 A7 A8
X2 A9 A10 A11 A12
X2 A13 A14 A15 A16
How to convert this :
FROM
X1 A1
X1 A2
X1 A3
X1 A4
X1 A5
X1 A6
X1 A7
X1 A8
X2 A9
X2 A10
X2 A11
X2 A12
X2 A13
X2 A14
X2 A15
X2 A16
TO
X1 A1 A2 A3 A4
X1 A5 A6 A7 A8
X2 A9 A10 A11 A12
X2 A13 A14 A15 A16
Hello emroull and welcome to the forum,
You haven't provided a sample file so I created a file using my best guess at how your data (X1, X2, A1, A2, etc) is laid out.
My macro is very simple and I have added some 1 second pauses so you can see it working. Just click the button "Run Macro" on Sheet1 to try it out.
If this is what you were hoping for, remember to mark the answer as "Selected".
Cheers :-)