+ Reply to Thread
Results 1 to 14 of 14

Workday formula not skipping weekend

  1. #1
    Registered User
    Join Date
    02-05-2009
    Location
    NC
    MS-Off Ver
    Excel 2007
    Posts
    30

    Workday formula not skipping weekend

    The Workday formula was working great until D23 where it failed to skip the weekend. It is the same formula for the entire column D, can't figure out why it stopped working.

    Thanks in advance for the help!

    Dale
    Attached Files Attached Files

  2. #2
    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
    79,369

    Re: Workday formula not skipping weekend

    What is wrong? What results are you expecting?
    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.

  3. #3
    Registered User
    Join Date
    02-05-2009
    Location
    NC
    MS-Off Ver
    Excel 2007
    Posts
    30

    Re: Workday formula not skipping weekend

    The formula is in every cell of Column D. D23 returns a Saturday date. D2:D22 skipped the weekends as it is supposed to.

  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
    79,369

    Re: Workday formula not skipping weekend

    Sorry - I realise that now and have changed my questions. Please tell us (a) which results are wrong and (b) what you expect the formula to return.

  5. #5
    Registered User
    Join Date
    02-05-2009
    Location
    NC
    MS-Off Ver
    Excel 2007
    Posts
    30

    Re: Workday formula not skipping weekend

    Quote Originally Posted by rdd2 View Post
    D23 returns a Saturday date. D2:D22 skipped the weekends as it is supposed to.
    I need column D to calculate column C plus column B, using only working hours and work days.

  6. #6
    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
    79,369

    Re: Workday formula not skipping weekend

    OK - so what results are you expecting to see in the cells that you asy are not calculating correctly? Don't leave us to work it out ourselves, please - just tell us so that we know what we are working towards. Thanks.

  7. #7
    Registered User
    Join Date
    02-05-2009
    Location
    NC
    MS-Off Ver
    Excel 2007
    Posts
    30

    Re: Workday formula not skipping weekend

    Sorry.

    C23 "4/12 10:50 a" + B23 "7" hours = "4/13 8:50 a"

    4/13 is a Saturday and should not be counted. D23 should equal "4/15 8:50 a" which is a Monday.

  8. #8
    Registered User
    Join Date
    02-05-2009
    Location
    NC
    MS-Off Ver
    Excel 2007
    Posts
    30

    Re: Workday formula not skipping weekend

    Working hours are 7:00a to 4:00p, Monday through Friday. They are referenced on the 'Info' sheet.

  9. #9
    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
    79,369

    Re: Workday formula not skipping weekend

    Thanks for the clarification.

  10. #10
    Forum Guru Bo_Ry's Avatar
    Join Date
    09-10-2018
    Location
    Thailand
    MS-Off Ver
    MS 365
    Posts
    7,211

    Re: Workday formula not skipping weekend

    Please try at
    D2
    =IF(B2="","",MOD(C2+MOD(IF(E2>0,E2,B2),9)/24,1)-"9:00"*(MOD(C2+MOD(IF(E2>0,E2,B2),9)/24,1)-"16:00">0)+WORKDAY(C2,(MOD(C2+MOD(IF(E2>0,E2,B2),9)/24,1)-"16:00">0)+INT(IF(E2>0,E2,B2)/9),Info!$A$2:$A$26))
    Attached Files Attached Files

  11. #11
    Registered User
    Join Date
    02-05-2009
    Location
    NC
    MS-Off Ver
    Excel 2007
    Posts
    30

    Re: Workday formula not skipping weekend

    That seems to work on Excel, but this workbook is used on Google sheets. This is the error message I get when using the above formula on Google sheets...

    "Function MOD parameter 1 expects number values. But 'ACTUAL' is a text and cannot be coerced to a number."

  12. #12
    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
    79,369

    Re: Workday formula not skipping weekend

    Nowhere until now did you mention this was not for Excel ...

    I have moved the thread to the correct section.

  13. #13
    Forum Guru Bo_Ry's Avatar
    Join Date
    09-10-2018
    Location
    Thailand
    MS-Off Ver
    MS 365
    Posts
    7,211

    Re: Workday formula not skipping weekend


  14. #14
    Registered User
    Join Date
    02-05-2009
    Location
    NC
    MS-Off Ver
    Excel 2007
    Posts
    30

    Re: Workday formula not skipping weekend

    Thank you Bo!

+ 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. Replies: 3
    Last Post: 01-03-2015, 03:33 PM
  2. [SOLVED] Include certain weekend in workday formula
    By szita2000 in forum Excel General
    Replies: 4
    Last Post: 12-16-2014, 03:02 PM
  3. Skipping the Weekend when autofilling dates
    By JakeMann in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 05-06-2014, 05:57 AM
  4. [SOLVED] Workday vs Weekend
    By nelkin in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 05-03-2013, 09:37 AM
  5. Workday.INTL or Workday function issue
    By junoon in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 01-17-2013, 03:14 PM
  6. [SOLVED] Weekend nightmare how to work out week day and weekend rates Help Please
    By Sherburn Systems in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-20-2012, 06:07 AM
  7. If function for workday & weekend
    By insplkm in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 11-12-2005, 09:30 PM

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