+ Reply to Thread
Results 1 to 3 of 3

Macro to transpose multiple rows into one row

  1. #1
    Registered User
    Join Date
    09-13-2019
    Location
    US
    MS-Off Ver
    office 365
    Posts
    7

    Macro to transpose multiple rows into one row

    Hello all,

    I'm wondering if this is possible. Here is a sample of a large data set:
    Capture.PNG

    I want to transpose these multiple rows into one row per service, id, name, age, street address with multiple phone numbers like this:
    Capture1.PNG

    Thank you guys
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    02-20-2011
    Location
    Florida, USA
    MS-Off Ver
    Windows 10, Excel 2013
    Posts
    1,569

    Re: Macro to transpose multiple rows into one row

    Your expected results sample does not match your narrative objective. Which do you want to use? Or do you want to redo your expected results.
    Any code provided by me should be tested on a copy or a mock up of your original data before applying it to the original. Some events in VBA cannot be reversed with the undo facility in Excel. If your original post is satisfied, please mark the thread as "Solved". To upload a file, click the 'Go Advanced' button, Then click 'Manage Attachements' and follow the menu.
    Thinking I am smart and knowing I am smart are two entirely different levels of schizophrenia.

  3. #3
    Forum Expert
    Join Date
    03-13-2004
    Location
    Gothenburg/Stockholm, Sweden
    MS-Off Ver
    Excel 2003, Excel 2007 & reluctant Excel 2010 user
    Posts
    4,270

    Re: Macro to transpose multiple rows into one row

    Like this perhaps? To test run macro "GetData" but still as JLG said your data is inconsistent as some of the persons have two different service so should there not be two lines in that case?

    Alf
    Attached Files Attached Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1