Results 1 to 3 of 3

Thread: Help me transposing multiple rows into one column with row labeling in Excel

  1. #1
    Join Date
    Jan 2012
    Posts
    17

    Help me transposing multiple rows into one column with row labeling in Excel

    Dear all,I need to convert the following table:
    a 1 2 3
    b 7 8
    c 4 5 6 9

    Into:
    a 1
    a 2
    a 3
    b 7
    b 8
    c 4
    c 5
    c 6
    c 9

    how to do it? Help appreciated.

  2. #2
    Join Date
    Feb 2009
    Posts
    156

    Re: Help me transposing multiple rows into one column with row labeling in Excel

    You can simply do it using Macros. Try out these Macros:
    Sub ReOrganize()
    'JBeaucaire (11/4/2009)
    'Turns row data into columnar data
    Dim LR As Long, i As Long, r As Long, c As Long, v As Long
    Application.ScreenUpdating = False

    LR = Range("A" & Rows.Count).End(xlUp).Row
    i = 1

    Do Until Range("A" & i) = ""
    If Range("C" & i) <> "" Then
    c = Cells(i, Columns.Count).End(xlToLeft).Column
    v = i
    For r = 3 To c
    i = i + 1
    Rows(i).Insert xlShiftDown
    Range("A" & i) = Range("A" & i - 1)
    Range("B" & i) = Cells(v, r)
    Next r
    End If
    i = i + 1
    Loop

    Range("C1", Cells(Rows.Count, Columns.Count)).ClearContents
    Application.ScreenUpdating = True
    End Sub

  3. #3
    Join Date
    Jan 2012
    Posts
    17

    Re: Help me transposing multiple rows into one column with row labeling in Excel

    Thanks a lot for the above solution! It works well.

    I also wanted to know Is it possible to put transposed data in a new sheet?

Similar Threads

  1. Replies: 3
    Last Post: 27-11-2010, 05:25 AM
  2. Multiple rows for same id on Oracle 10
    By KADIN in forum Software Development
    Replies: 4
    Last Post: 23-11-2009, 05:20 PM
  3. How to Insert Multiple Rows At Once in PHP
    By Zeverto in forum Software Development
    Replies: 3
    Last Post: 22-09-2009, 03:30 PM
  4. Replies: 2
    Last Post: 09-07-2009, 08:57 AM
  5. Auto hide rows and column in Excel 2007
    By Murena in forum Windows Software
    Replies: 3
    Last Post: 28-02-2009, 07:00 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Page generated in 1,713,577,411.51319 seconds with 17 queries