+ Reply to Thread
Results 1 to 3 of 3

Combining/merging rows when a common e-mail address is found

  1. #1
    Registered User
    Join Date
    07-08-2013
    Location
    Boston
    MS-Off Ver
    Excel 2010
    Posts
    1

    Combining/merging rows when a common e-mail address is found

    I am having trouble drilling down a database of contacts that was recently passed on to me. Each contact can have up to five different phone numbers. Rather than having one entry per contact with all of the phone numbers itemized normally, anytime the phone number count exceeds one, a new entry is created for that contact with all identical information with the exception of the number. So for example, my table may look like:

    Contact e-mail Phone Fax Cell
    [email protected] 555-1234
    [email protected] 555-4321
    [email protected] 555-6789

    I am trying to get a piece of code that can go down through the contact email, if the preceding cell is a duplicate move the phone number value up one row, delete the secondary row, and move on to the next row. My spreadsheet has about 4700 rows, so any automation tips that could be provided would be greatly appreciated!

  2. #2
    Forum Guru
    Join Date
    07-25-2011
    Location
    Florida
    MS-Off Ver
    Excel 2003
    Posts
    9,643

    Re: Combining/merging rows when a common e-mail address is found

    Change the column letters in the code to suit. Test this on a copy of your data.

    Please Login or Register  to view this content.
    Surround your VBA code with CODE tags e.g.;
    [CODE]your VBA code here[/CODE]
    The # button in the forum editor will apply CODE tags around your selected text.

  3. #3
    Forum Guru
    Join Date
    03-02-2006
    Location
    Los Angeles, Ca
    MS-Off Ver
    WinXP/MSO2007;Win10/MSO2016
    Posts
    12,612

    Re: Combining/merging rows when a common e-mail address is found

    Please Login or Register  to view this content.
    Or...
    Please Login or Register  to view this content.
    Last edited by protonLeah; 07-08-2013 at 10:54 PM.
    Ben Van Johnson

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1