+ Reply to Thread
Results 1 to 3 of 3

Locating Max Date based on adjacent cell

  1. #1
    Registered User
    Join Date
    11-22-2009
    Location
    Singapore
    MS-Off Ver
    Excel 2003
    Posts
    12

    Locating Max Date based on adjacent cell

    Dear Excel folks,

    I am trying to write a vba code that can identify the max date from column using based on an adjacent value as reference
    Have tried using of array formulas but it slows down the processing time quite considerably

    Below is a sample ranging from A1 to C8

    _____ A____ |____B____ I__C__|
    1 | Jane Doye | 01/01/2005 | No
    2 | Tom Smith | 01/01/2011 | Yes
    3 | Jane Doye | 01/01/2004 | No
    4 | Jane Doye | 01/01/2008 | No
    5 | Jane Doye | 01/01/2006 | No
    6 | Jane Doye | 01/01/2010 | Yes
    7 | Jane Doye | 01/01/2009 | No
    8 | Tom Smith | 01/01/2008 | No

    Basing on the above example, once the macros is triggered, column C will display string "Yes" if the row contains the latest date - based on the individual in column A

    I hope the sample is sufficiently concise and clear!
    Looking forward to any directions on this.

    Thanks
    Jensen

  2. #2
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: Locating Max Date based on adjacent cell

    Hello Jensen,

    This macro starts with cell "A1" of the active sheet. It expects the date to be in the righthand adjacent cell in column "B". You can change "A1" to whatever starting cell you want.
    Please Login or Register  to view this content.
    Sincerely,
    Leith Ross

    Remember To Do the Following....

    1. Use code tags. Place [CODE] before the first line of code and [/CODE] after the last line of code.
    2. Thank those who have helped you by clicking the Star below the post.
    3. Please mark your post [SOLVED] if it has been answered satisfactorily.


    Old Scottish Proverb...
    Luathaid gu deanamh maille! (Rushing causes delays!)

  3. #3
    Registered User
    Join Date
    11-22-2009
    Location
    Singapore
    MS-Off Ver
    Excel 2003
    Posts
    12

    [SOLVED] Re: Locating Max Date based on adjacent cell

    Thanks! It works perfect!

+ 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