+ Reply to Thread
Results 1 to 5 of 5

Vacation Pro-ration Formulas to encompass Leave time off

  1. #1
    Forum Contributor
    Join Date
    05-12-2021
    Location
    USA
    MS-Off Ver
    Microsoft Office 365
    Posts
    259

    Vacation Pro-ration Formulas to encompass Leave time off

    Hello, I am looking for some help on formulas that will calculate how many days someone has been out on a specific leave and this time it is within a specified window of time. Refer to this post which I received a solution for earlier:

    https://www.excelforum.com/excel-for...e-entries.html

    What I'm looking for now basically expands upon that thread. Here goes...

    So what the previous thread does is it conditionally formats a person's name to light up if they have exceeded a certain amount of days being out on either one or another type of leave of absence. The two leave types are A&S and WC. If they are on A&S, the trigger to light the cell up is if they are out on leave 90 days or more. If it is WC, the trigger to light up is 6 months or more. The sheet takes into account people going on multiple leaves in a year and so is actually looking for the combined total number days they were out among several leaves of absence.

    What I am now looking to do is see how much of that time taken off falls within a specified window of time. On the sheet I have attached, that window of time would be the date range found in Columns D and E, the vacation date and the vacation period end date. As information, Column L has the date the employee actually started their leave of absence while column M has when they returned to work. So basically, I probably need to add an additional column called Days off within pro-rated window. We can just designate column T for that now and it can be moved later as we need. (Bear with me as we are still kind of building/finalizing this file to determine exactly what columns we want, where we want them, etc.) So again, if I can know the amount of days absent within D and E range and have that number populate in Column T.

    After that, the next step is in column F, the Pro-rated 2022 column. It should say "Yes" if column K is A&S and column T is greater than or equal to 90 days OR if column K is WC and column T is greater than or equal to 6 months. If none of those conditions are met, it can simply say "No". Bear in mind that as with the previous post referenced, It should take into account employees going on multiple leaves during that window of pro-ration and therefore adding those leaves together. So if someone has a pro-ration period of March of this year to March of next year, but they go out on an A&S leave say in in January of this year, it should only count what is taken after that March window. Let's say their first leave taken in January goes well after March and actually totals 50 days in that March period. 50 days is fine, no pro-ration needed. But lets say then that they go on another leave after that and that one happens to total 45 days. Well now, that leave is purely within that March window unlike the first so now we do total 95 days and in that case, column F should say "Yes"

    I hope I explained this clear enough as it was a mouthful. Please let me know though if something need clarified and I will do my best. Thank you so much in advance for any help with this!
    Attached Files Attached Files
    Last edited by PitchNinja; 10-19-2021 at 02:16 PM.

  2. #2
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    30,827

    Re: Vacation Pro-ration Formulas to encompass Leave time off

    Using column H (Days Absent)

    in F2

    =IF(OR(AND([@[Reason for Leave]]="A&S",[@[Days Absent]]>=90),AND([@[Reason for Leave]]="WC",[@[Days Absent]]>=180)),"Yes","No")
    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED.

  3. #3
    Forum Contributor
    Join Date
    05-12-2021
    Location
    USA
    MS-Off Ver
    Microsoft Office 365
    Posts
    259

    Re: Vacation Pro-ration Formulas to encompass Leave time off

    Hi John, thanks as always for the response and your help. So that formula does work for column H's days absent, but unfortunately, column H is actually just a grand total amount of the days they were out on any amount of leave based on columns L and M. (they had wanted that total as well for some other use) It is not necessarily how many days they were on a leave within their pro-ration window period which would start in column D and end in column E. That's what I was thinking column T could be used for. We could just call that column Days Absent within pro-ration window and kinda do a comparison maybe of columns L and M and then columns D and E to see how many days the the L/M range fall within the D/E range. That would then ultimately be what column F is driven off of is the data in column T. I hope that makes more sense?

  4. #4
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2504 (Windows 11 Home 24H2 64-bit)
    Posts
    90,719

    Re: Vacation Pro-ration Formulas to encompass Leave time off

    Refer to this post which I received a solution for earlier:
    Please don't expect members to cross reference other threads. Please include all relevant detail in this thread. Thanks.
    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. It's a universal courtesy.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    NB:
    as a Moderator, I never accept friendship requests.
    Forum Rules (updated August 2023): please read them here.

  5. #5
    Forum Contributor
    Join Date
    05-12-2021
    Location
    USA
    MS-Off Ver
    Microsoft Office 365
    Posts
    259

    Re: Vacation Pro-ration Formulas to encompass Leave time off

    I think I found something! So I used this formula which I found here: https://exceljet.net/formula/calcula...verlap-in-days

    I wasn't sure if it would work but it seems to:

    In T2:
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    I've never used a Min/Max formula before but it seems like this is doing what I need it to do. You will see that I added a column U and that column has the current date in it. The formula as I want it to is comparing the two date ranges, D and E and L and M, If column M - their return to work date - has no value in it, the formula is going to use column U(today's date) which will keep a running total and update daily, and therefore the names will light up in columns A and B based on the value that is in column T instead of H. If there is a better formula I should have used, perhaps someone could advise?

+ 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] Anniversary Start date to reset Employees Sick leave and Vacation Time
    By TheSpa88 in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 04-21-2021, 11:36 AM
  2. Sick/Vacation leave accrual
    By jzamoralopez in forum Excel General
    Replies: 1
    Last Post: 12-05-2018, 11:06 PM
  3. [SOLVED] Populating vacation leave.
    By aries_01463 in forum Excel General
    Replies: 2
    Last Post: 09-28-2015, 01:53 AM
  4. Replies: 5
    Last Post: 03-03-2015, 01:38 PM
  5. Vacation and Sick Leave Accrual formula
    By Dowjd in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 10-01-2013, 10:24 PM
  6. Vacation/Sick Leave accruals
    By Carisa in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 09-27-2012, 09:47 PM
  7. Varifying whether 2 imes encompass a time band
    By fraserjamie in forum Excel General
    Replies: 4
    Last Post: 09-25-2008, 06:28 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