+ Reply to Thread
Results 1 to 5 of 5

Help with formula to auto create break times

  1. #1
    Forum Contributor
    Join Date
    12-15-2005
    MS-Off Ver
    Office 2007
    Posts
    346

    Help with formula to auto create break times

    This is a complicated formula, at least not something I can do.

    There is an draft attached to this email.

    Rules:
    First rule is that no breaks can overlap.
    1st Break is 40 Mins.
    2nd Break is 20 Mins.
    1st Break is at least 2 Hours After Time-In.
    2nd Break is at least 2 Hours Before from Time-Out.
    Each Employee might have a unavailable time for breaks.

    Not sure if it is possbile to create a formula like this, or I might need an Excel Wizard to do this.

    thanks for any help,

    Nick
    Attached Files Attached Files

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Help with formula to auto create break times

    Hi Nick,

    You need to add the results you expect in columns C&D since it's not obvious from your post exactly what you require. You should also add notes explaining how you arrive at the results.

    For instance when you say no breaks should overlap do you mean for each employee only or across all employees? In which case who takes precedence.
    Using terms like 'at least' is no help when constructing a formula since it's open to interpretation.
    Exactly how are the unavailable times to be used? Do you mean a break can't start within the unavailable time. Can they start a break before the unavailable time but which runs into the unavailable time?

    Do employees work past midnight, i.e. is the time out less than the start time but on the next day?
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  3. #3
    Forum Contributor
    Join Date
    12-15-2005
    MS-Off Ver
    Office 2007
    Posts
    346

    Re: Help with formula to auto create break times

    Thanks for the input, I placed an updated example to this post.

    I hope I was able to describe it properly, easy to see it in my head and when it comes to putting it down is another thing.


    Thanks,
    Nick
    Attached Files Attached Files

  4. #4
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Help with formula to auto create break times

    Hi,

    Do the following formulae do what you want.
    C3 and copied down
    Please Login or Register  to view this content.
    D3 and copied down
    Please Login or Register  to view this content.

  5. #5
    Forum Contributor
    Join Date
    12-15-2005
    MS-Off Ver
    Office 2007
    Posts
    346

    Re: Help with formula to auto create break times

    Thank you,

    I test out the code but there are conflicts, break times overlaping and I tested the unavailble times with a 1:00-3:00 PM time and it scheduled them at 1:40.

    I attached an updated sample with the code, you can see how things conflict with each other.

    Thank you for your help.
    Nick
    Attached Files Attached Files

+ 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