+ Reply to Thread
Results 1 to 5 of 5

find the first which met the condition

  1. #1
    Registered User
    Join Date
    12-21-2019
    Location
    vietnam
    MS-Off Ver
    microsoft 2016
    Posts
    2

    find the first which met the condition

    Hi everyone,

    I have a file that contain chat history, so I would like to find the time of the first message that sent by real agent.
    demo.PNG

    Can anyone sugguest me the function that can solve my case?

  2. #2
    Valued Forum Contributor saravnepali's Avatar
    Join Date
    01-14-2019
    Location
    Sydney Australia
    MS-Off Ver
    2010
    Posts
    447

    Re: find the first which met the condition

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    If you want the time in column N, put this formula and drag down.

    Also, for future please attach the spreadsheet rather then the image so that its easier to check the formula.
    If you think someone helped you, click on the "* Add Reputation" as a way to say thank you.

    If your problem is solved, go to Thread Tools and select Mark This Thread Solved

  3. #3
    Registered User
    Join Date
    12-21-2019
    Location
    vietnam
    MS-Off Ver
    microsoft 2016
    Posts
    2

    Re: find the first which met the condition

    thank you for your support, but actually what I want is calculate the time between the first message of visitor and the first response time of agent. You can see visitor always place in the first event, but not for agents, they may place in second event or the third.
    For example with id =1, what I want is a function that is able to detect time of message that send by agent then subtract it with the time of event 1.
    Also, thanks for your advice, I attach the file hereAttachment 654951

  4. #4
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,780

    Re: find the first which met the condition

    You need this:

    =OFFSET($A2,0,MATCH("Agent",A2:M2,0))-E2

    However the entry in E2 is a date and time - this needs changing to just a time.
    Attached Files Attached Files
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  5. #5
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,036

    Re: find the first which met the condition

    or (to avoid the OFFSET function which recalculates every time ANTHING is changed - and which can cause performance issues in big datasets):

    =INDEX(2:2,,MATCH("agent",2:2,0)+1)-E2
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU.

    Temporary addition of accented to illustrate ongoing problem to the TT: L? fh?ile P?draig sona dhaoibh

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Find certain string with condition.
    By HXIO in forum Excel General
    Replies: 2
    Last Post: 04-30-2019, 06:15 AM
  2. [SOLVED] how to delete the row after the first find condition and until before second find conditi
    By Step01 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-10-2018, 01:40 AM
  3. Using condition IF with Find
    By bdb1974 in forum Excel General
    Replies: 5
    Last Post: 02-02-2010, 12:46 PM
  4. Can i Use Condition in Find()
    By chinna9649 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 10-18-2009, 10:43 AM
  5. find, meet condition, sum range, deduce, find next
    By pinstripe in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 09-27-2007, 09:30 AM
  6. If Condition Then find and delete
    By Paul Morgan in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 11-06-2006, 08:48 AM
  7. Find and replace with condition
    By Stuart in forum Excel General
    Replies: 5
    Last Post: 07-26-2005, 08:05 AM

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