+ Reply to Thread
Results 1 to 3 of 3

VBA code to find duplicate and combine their values

  1. #1
    Registered User
    Join Date
    08-16-2013
    Location
    Czech republic
    MS-Off Ver
    Excel 2010
    Posts
    7

    VBA code to find duplicate and combine their values

    Hello,
    I´m looking for macro that goes thru data in one column at sheet 1 to find duplicates, then export duplicate text to another sheet and combine their values as text.

    for example:

    Inbut data
    A____________B
    CZ___________1
    EU___________9
    CZ___________13
    CZ___________23
    EU___________31

    output on another sheet:
    A__________B
    CZ_________1, 13, 23
    EU_________9, 31


    Thank you for help
    Last edited by tohor; 08-16-2013 at 02:52 AM.

  2. #2
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: VBA code to find duplicate and combine their values

    MERGE ROWS
    Here's a macro for merging rows of data using the ID in column A and putting the column B values together in a delimited manner of your choosing. There's a sample file as well for testing.There's a sample workbook too you could drop your data into and test it out.
    Last edited by JBeaucaire; 12-27-2019 at 04:31 AM.
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

  3. #3
    Registered User
    Join Date
    08-16-2013
    Location
    Czech republic
    MS-Off Ver
    Excel 2010
    Posts
    7

    Re: VBA code to find duplicate and combine their values

    Thank you very much!

    Is there any chance to keep source datas and export merged rows on another sheet?

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Combine duplicate, sequential values, then group into a range
    By engineerlady in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-26-2013, 10:28 AM
  2. [SOLVED] Parse data and combine values for duplicate entries for the same date
    By rlaserra in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-19-2012, 10:27 PM
  3. VBA code to find duplicate values within multiple rows and columns
    By pcbpinoy in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 10-27-2011, 09:04 PM
  4. Detect/find Duplicate Values In Code
    By FRIEL in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-14-2008, 11:02 AM
  5. Find and combine duplicate rows
    By treva26 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 09-09-2007, 09:14 PM

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