+ Reply to Thread
Results 1 to 4 of 4

Need A MACRO to Remove Duplicate Name Header and Stack

  1. #1
    Registered User
    Join Date
    08-26-2012
    Location
    India
    MS-Off Ver
    Excel 2003
    Posts
    58

    Need A MACRO to Remove Duplicate Name Header and Stack

    Hi All,
    I am trying but not getting what logic I can use. Can anyone help me on this?
    I have some data with header to each data set having a name. For some Name “_M” has been suffixed. So my requirement is

    1. Remove ”_M” for the names. (That’s not difficult).

    2. After removal of of all”_M”, if the two name are same then they need to be shown in one stack under one name.

    I want to add that the input I am using will like always that same name (for example “abc” and “abc_M”) will be stacked one below one.

    Attached the input and Output needed.

    Thanks in Advance,
    Attached Files Attached Files

  2. #2
    Forum Expert mrice's Avatar
    Join Date
    06-22-2004
    Location
    Surrey, England
    MS-Off Ver
    Excel 2013
    Posts
    4,967

    Re: Need A MACRO to Remove Duplicate Name Header and Stack

    Try this

    Please Login or Register  to view this content.
    Open up the VBA editor by hitting ALT F11

    Insert a new module by hitting Insert - Module

    Paste the macro into the empty sheet

    Hit ALT F11 to get back to the worksheet.

    Run the macro by going to tools-macro in Excel 2003 or the view ribbon in Excel 2007/2010.
    Martin

  3. #3
    Registered User
    Join Date
    08-26-2012
    Location
    India
    MS-Off Ver
    Excel 2003
    Posts
    58

    Re: Need A MACRO to Remove Duplicate Name Header and Stack

    Thank you mrice..Thank you very much. That's is just fine.Wish u happy New Year....

  4. #4
    Forum Expert
    Join Date
    11-28-2012
    Location
    Guatemala
    MS-Off Ver
    Excel 2010
    Posts
    2,394

    Re: Need A MACRO to Remove Duplicate Name Header and Stack

    Try this macro
    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