+ Reply to Thread
Results 1 to 10 of 10

Calculate downtime between two dates exclude weekends

  1. #1
    Registered User
    Join Date
    12-06-2012
    Location
    malaysia
    MS-Off Ver
    Excel 2007
    Posts
    7

    Calculate downtime between two dates exclude weekends

    Hi,

    I'm new to this forum and i need to check the downtime in minutes for a start and end date, whereby it needs to exclude weekends.

    i have tried using the networkdays, but it only return me with the day, but i need the actual downtime in minutes. I really have no idea Can assist ? or point me to useful sources that for newbie like able to follow?

  2. #2
    Forum Expert
    Join Date
    06-09-2010
    Location
    Australia
    MS-Off Ver
    Excel 2013
    Posts
    1,714

    Re: Calculate downtime between two dates exclude weekends

    hi
    if a machine is off for a whole day, do you want that counted as 24 hours or only a work day (eg 8 hours)? if the latter, how long is your working day?

  3. #3
    Registered User
    Join Date
    12-06-2012
    Location
    malaysia
    MS-Off Ver
    Excel 2007
    Posts
    7

    Re: Calculate downtime between two dates exclude weekends

    whole day, as 24 hours

  4. #4
    Forum Contributor dogberry's Avatar
    Join Date
    07-15-2012
    Location
    Wales, UK
    MS-Off Ver
    Excel 2010
    Posts
    624

    Re: Calculate downtime between two dates exclude weekends

    Hi

    =(NETWORKDAYS(A2,B2,holidays)-1)*(J$3-J$2)+MOD(B2,1)-MOD(A2,1)

    A2 = start time/date
    B2 = end time/date
    J2 = MF start time, e.g. 08:00
    J3 = MF end time e.g. 18:30
    holidays = named range containing holiday dates

    See if this works for you


    Chris
    Click my star if I helped Thanks

  5. #5
    Registered User
    Join Date
    12-06-2012
    Location
    malaysia
    MS-Off Ver
    Excel 2007
    Posts
    7

    Re: Calculate downtime between two dates exclude weekends

    Start date :Oct 16, 2012 8:00:00 AM
    End Date : Oct 22, 2012 10:00:00 AM

    But it returns 24.41666667 - not sure if this is minutes ??

  6. #6
    Forum Expert dredwolf's Avatar
    Join Date
    10-27-2012
    Location
    Clearwater,Canada
    MS-Off Ver
    Excel 2007
    Posts
    2,649

    Re: Calculate downtime between two dates exclude weekends

    I think that is returning hours (?)..not sure of holidays/days off ...BUT if it is hrs, just multiply by 60 to get minutes ..
    A picture may be worth a thousand words, BUT, a sample Workbook is worth a thousand screenshots!
    -Add a File - click advanced (next to quick post), scroll to manage attachments, click, select add files, click select files, select file, click upload, when file shows up at bottom left, click done (bottom right), click submit
    -To mark thread Solved- go top of thread,click Thread Tools,click Mark as Solved
    If you received helpful response, please remember to hit the * of that post

  7. #7
    Forum Expert
    Join Date
    06-09-2010
    Location
    Australia
    MS-Off Ver
    Excel 2013
    Posts
    1,714

    Re: Calculate downtime between two dates exclude weekends

    try this

    it should return total hours in whole numbers and decimals (ie 9 hours 30 minutes = 9.5)

    =24*(NETWORKDAYS(A2,B2)-MOD(A2,1)-(1-MOD(B2,1)))

  8. #8
    Forum Expert dredwolf's Avatar
    Join Date
    10-27-2012
    Location
    Clearwater,Canada
    MS-Off Ver
    Excel 2007
    Posts
    2,649

    Re: Calculate downtime between two dates exclude weekends

    Quote Originally Posted by annice View Post
    but i need the actual downtime in minutes
    anything that is returning hours down, just multiply by 60..that will give you minutes down...
    just enclose the formula in braces.."(formula) * 60"..

    Hope this helps

  9. #9
    Registered User
    Join Date
    12-06-2012
    Location
    malaysia
    MS-Off Ver
    Excel 2007
    Posts
    7

    Re: Calculate downtime between two dates exclude weekends

    Ya, i guess is good to include the file for better understanding on the problem.

    I working on calculating the machine downtime where the possible is:
    1. The machine operation could be 31 days * 24 hours
    2. The machine operation could be 23 days * 8 hours (where by the working hours is from 9AM till 5PM, exclude weekends)

    I have difficulties in calculating the downtime for the No. 2 above.
    Attached Files Attached Files

  10. #10
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    Microsoft 365
    Posts
    14,695

    Re: Calculate downtime between two dates exclude weekends

    This formula in H2 will give you the working minutes only (9 to 5 MF) whatever the start and end times

    =((NETWORKDAYS(D2,E2)-1)*(17-9)+IF(NETWORKDAYS(E2,E2),MEDIAN(MOD(E2,1)*24,9,17),17)-MEDIAN(NETWORKDAYS(D2,D2)*MOD(D2,1)*24,9,17))*60
    Audere est facere

+ 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