+ Reply to Thread
Results 1 to 2 of 2

If and condition to calculate time

  1. #1
    Registered User
    Join Date
    11-16-2022
    Location
    India
    MS-Off Ver
    Microsoft 16
    Posts
    6

    If and condition to calculate time

    Hi All,
    I am trying to derive a formula to calculate volume inflow. For example, our shift timing is 1 PM to 1 AM. So, any volume which is received between 1 AM to 1 PM to be considered as 1 PM only. To be more precise, if volume is received 03/24/2023 00:59:00 AM to be considered as same time; however, if volume is received at 03/24/2023 01:20:15 AM, then it should be considered as 03/24/2023 01:00:00 AM. Same way if it is received on 03/24/2023 11:56:00 AM, then it should be considered as 03/24/2023 01:00:00 PM.

    I am trying with IF AND condition, but it throws FALSE. Kindly assist.

    A B
    Received_Date Closed_Date
    1/28/2023 0:16 1/30/2023 15:05 12:16:00 AM FALSE
    1/28/2023 1:18 1/30/2023 15:12 01:18:00 AM FALSE

    formula used was =IF(AND(A2>="01:00:00 AM",A2<="01:00:00 PM"),"01:00:00 PM")
    Attached Files Attached Files

  2. #2
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,409

    Re: If and condition to calculate time

    Not sure 100% I can understand, but:
    use:
    Please Login or Register  to view this content.
    or
    Please Login or Register  to view this content.
    I wish you could manual input some expected results
    Quang PT

+ 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] Calculate time of arrival with IF condition based on departure
    By Havreliuc in forum Excel Formulas & Functions
    Replies: 18
    Last Post: 05-25-2022, 11:07 AM
  2. Replies: 3
    Last Post: 03-18-2021, 05:58 AM
  3. How to calculate time worked: Start time, end time, lunch break
    By khalinguyen191999 in forum Excel General
    Replies: 1
    Last Post: 09-14-2020, 11:37 PM
  4. Replies: 7
    Last Post: 04-25-2020, 03:23 AM
  5. VBA calculate sleep time, when time is entered in military time format
    By axm1955 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 09-29-2017, 10:28 AM
  6. [SOLVED] How to calculate time differences with condition
    By harimin in forum Excel General
    Replies: 3
    Last Post: 02-01-2016, 11:07 PM
  7. [SOLVED] Calculate time in days from current with special condition
    By Nairobi Nice in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 04-19-2012, 10:26 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