Transferring data from a column into several rows
Closed
LJ30
Posts
1
Registration date
Saturday May 25, 2013
Status
Member
Last seen
May 25, 2013
-
May 25, 2013 at 07:51 PM
TrowaD Posts 2921 Registration date Sunday September 12, 2010 Status Moderator Last seen December 27, 2022 - May 28, 2013 at 09:45 AM
TrowaD Posts 2921 Registration date Sunday September 12, 2010 Status Moderator Last seen December 27, 2022 - May 28, 2013 at 09:45 AM
Related:
- Transferring data from a column into several rows
- Transfer data from one excel worksheet to another automatically - Guide
- Tmobile data check - Guide
- How to transfer ff id from facebook to google - Guide
- Display two columns in data validation list but return only one - Guide
- Gta 5 data download for pc - Download - Action and adventure
1 response
TrowaD
Posts
2921
Registration date
Sunday September 12, 2010
Status
Moderator
Last seen
December 27, 2022
555
May 28, 2013 at 09:45 AM
May 28, 2013 at 09:45 AM
Hi LJ30,
The following code will copy range A1:A200 and paste it to B1:GS1.
The groups of 4 or cut/pasted to the range B1:E50.
So make sure those 2 ranges don't contain data, otherwise create a new sheet.
After the code has done it's work delete column A to get the desired result.
Here is the code:
To use the code:
Alt+F11 > top menu in new window > insert > module > paste code in big white field.
Back at excel at the correct sheet hit Alt+F8 and double-click TransposeIn4.
Best regards,
Trowa
The following code will copy range A1:A200 and paste it to B1:GS1.
The groups of 4 or cut/pasted to the range B1:E50.
So make sure those 2 ranges don't contain data, otherwise create a new sheet.
After the code has done it's work delete column A to get the desired result.
Here is the code:
Sub TransposeIn4() Dim x, y As Integer Range("A1:A200").Copy Range("B1").PasteSpecial Transpose:=True x = 2 y = 1 Do x = x + 4 y = y + 1 Range(Cells(1, x), Cells(1, x + 3)).Cut _ Range("B" & y) Loop Until y = 50 End Sub
To use the code:
Alt+F11 > top menu in new window > insert > module > paste code in big white field.
Back at excel at the correct sheet hit Alt+F8 and double-click TransposeIn4.
Best regards,
Trowa