Hi there, I wish to transpose multiple lines into one column, I have attached a file for an example. Thank you for your help.
Hi there, I wish to transpose multiple lines into one column, I have attached a file for an example. Thank you for your help.
Last edited by Doodie; 12-15-2012 at 04:45 PM.
Try this:
![]()
Sub RowstoColumn(): Dim Ro As Range, r As Long: r = 7 SetRo: Set Ro = Range("F" & r & ":J" & r): Ro.Copy Range("A" & r).PasteSpecial Transpose:=True r = r + 5 If Range("F" & r) = "" Then Exit Sub GoTo SetRo: End Sub
If I've helped you, please consider adding to my reputation - just click on the liitle star at the left.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~(Pride has no aftertaste.)
You can't do one thing. XLAdept
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~aka Orrin
Thank you, it works. I need to learn VBA, it would save so much time.
You're welcome! - Yeah, I really like VBA and Excel.
write at A7 :
=TRANSPOSE(E7:I7)
then select range A7:A11 (5 rows)
push Ctrl +shift +enter (array formula)
copy result down
Another
![]()
Sub abc() Dim i As Long For i = 7 To Cells(Rows.Count, "a").End(xlUp).Row Step 5 Cells(i, "e").Resize(, 5) = _ Application.Transpose(Cells(i, "a").Resize(5)) Next End Sub
Thanks,
Mike
If you are satisfied with the solution(s) provided, please mark your thread as Solved.
Select Thread Tools-> Mark thread as Solved.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks