+ Reply to Thread
Results 1 to 3 of 3

Find and display the last occurance in two columns and display related cell

  1. #1
    Registered User
    Join Date
    10-26-2012
    Location
    Manhattan, Kansas
    MS-Off Ver
    Excel 2007
    Posts
    17

    Find and display the last occurance in two columns and display related cell

    Hey guys,

    I am looking for a formula to insert into the INSPECTIONS Last Completed table which is attached. The formula needs to display the hours when the last inspection took place for each vehicle, and as you can see it needs to look for the inspection value in both columns C and D but only display the last occurance for either one. Also in the attachment is the desired result and sample data to build the equation with. Thanks for the help!

    willia97
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    01-15-2007
    Location
    Brisbane, Australia
    MS-Off Ver
    2007
    Posts
    6,591

    Re: Find and display the last occurance in two columns and display related cell

    Hi

    K37: =INDEX($E$1:$E$25,MAX(IF(($B$2:$B$25=$I36)*($C$2:$C$25=K$36),ROW($B$2:$B$25),""),IF(($B$2:$B$25=$I36)*($D$2:$D$25=K$36),ROW($B$2:$B$25),""))) Note this formula is array entered (CTRL, SHIFT, ENTER). Copy across / down as required.

    rylo

  3. #3
    Valued Forum Contributor
    Join Date
    09-10-2012
    Location
    Los Angeles, CA
    MS-Off Ver
    Excel 2010
    Posts
    929

    Re: Find and display the last occurance in two columns and display related cell

    Willia,

    This is what I came up with... very close to rylo...

    =INDEX($E$2:$E$25,MAX(MAX(($B$2:$B$25=$I36)*($C$2:$C$25=K$36)*ROW($C$2:$C$25)),MAX(($B$2:$B$25=$I36)*($D$2:$D$25=K$36)*ROW($D$2:$D$25)))-1,1)

    Also, needs the array-enter (CTRL-SHIFT-ENTER).

    Dennis

+ 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