+ Reply to Thread
Results 1 to 2 of 2

How to find duplicate entries, and delete the earlier modified entry?

  1. #1
    Registered User
    Join Date
    03-05-2010
    Location
    Singaproe
    MS-Off Ver
    Excel 2007
    Posts
    18

    How to find duplicate entries, and delete the earlier modified entry?

    Hi everyone,

    I have a problem with duplicate removing.

    My WorkbookA currently copies one whole workbook from an external spreadsheet and copies it into a new sheet.

    My code currently uses a duplicate removal method via sorting. This means after sorting the copied data, the code will leave behind the entry with the lowest price and delete others.

    For e.g.
    Hello $0.02
    Hello $0.03
    Hello $0.04

    After running, the code will leave only:
    Hello $0.02

    Right now, my colleague is asking me if it is possible to find out which duplicate entries are modified latest, and delete the earlier modified entry.

    For me, the trouble is:
    1) I don't know how to sort by modified date/time, if it is possible at all.
    2) The data I am sorting is copied over from another workbook into WorkbookA. So I guess all the date/time records are erased?

    Thanks in advance!

  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: How to find duplicate entries, and delete the earlier modified entry?

    There's no built-in record of the changes occurring in which cell. But you can probably add date/time stamps in another column in your original data so it becomes a piece of analyzable datum. If that gets imported along with the prices, it's easy to keep the most recent price then.
    _________________
    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!)

+ 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