+ Reply to Thread
Results 1 to 5 of 5

IF Formula. Time between 2 dates taking into account Blank fields

  1. #1
    Registered User
    Join Date
    04-03-2014
    Location
    London
    MS-Off Ver
    Excel 2010
    Posts
    39

    IF Formula. Time between 2 dates taking into account Blank fields

    Hello

    I'm trying to work out how long a process is taking at several stages at the point the spreadsheet opens.

    Formula I have is below.

    =NETWORKDAYS(G4,S4,'Bank Holidays'!A1:A387)-1

    I need to add an IF formula to show that IF S4 is blank then use today's date. This is in Cell B1. If it isn't blank then just use the date in the field.

    Played around and I'm getting a bit stuck.

    Help is appreciated.

    Thanks
    Matt

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

    Re: IF Formula. Time between 2 dates taking into account Blank fields

    Hi there. try this out:

    =IF(S4="",NETWORKDAYS(G4,TODAY(),'Bank Holidays'!A1:A387)-1,NETWORKDAYS(G4,S4,'Bank Holidays'!A1:A387)-1)
    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

  3. #3
    Registered User
    Join Date
    07-22-2014
    Location
    Riyadh
    MS-Off Ver
    2010
    Posts
    88

    Re: IF Formula. Time between 2 dates taking into account Blank fields

    =NETWORKDAYS(G4,IF(S4="",TODAY(),S4),'Bank Holidays'!A1:A387)-1

  4. #4
    Forum Expert NeedForExcel's Avatar
    Join Date
    03-16-2013
    Location
    Pune, India
    MS-Off Ver
    Excel 2016:2019, MS 365
    Posts
    3,879

    Re: IF Formula. Time between 2 dates taking into account Blank fields

    Here!

    Please Login or Register  to view this content.
    But today is a Volatile function.. The Today's Date thats visible today will change everyday.. Let me know if thats not what you want

    Hope it helps!
    Cheers!
    Deep Dave

  5. #5
    Registered User
    Join Date
    04-03-2014
    Location
    London
    MS-Off Ver
    Excel 2010
    Posts
    39

    Re: IF Formula. Time between 2 dates taking into account Blank fields

    Thanks I do need it to change everyday, mainly to prompt fields to be filled in.

    I've now got a part 2 that has come about with this formula that is slightly separate. I need the calculation to look at 2 start dates.

    IF Q4= "N/A" (Text) then use N4
    IF Q4= "A date" then use Q4

    Tried to start this off myself below, but need to add the counter

    =NETWORKDAYS($M4,IF($Q4="N/A",$N4),'Bank Holidays'!$A$1:$A$387)-1

    Help is always appreciated.

    Thanks
    Matt

+ 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. Find Min Time taking 24hrs into account
    By kiktuo in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 11-24-2014, 09:06 PM
  2. Countif Formula taking into account start dates
    By Revolution in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 10-15-2013, 12:17 PM
  3. Replies: 5
    Last Post: 05-18-2012, 10:24 AM
  4. Replies: 3
    Last Post: 03-09-2012, 08:19 AM
  5. Replies: 0
    Last Post: 01-09-2012, 04:20 PM

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