LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 353
Default Figuring Vacation Hrs. Earned using Current Date minus Hire Da

Actually, upon reflection, it doesn't give them their increase until the day
after their anniversary... use this one to update ON their anniversary date.
=HLOOKUP(A2-B2,{0,364.26,1094.78,3651.6;0,40,80,120},2)

"BoniM" wrote:

With A1 your current date and B1 your hire date:
=HLOOKUP(A1-B1,{0,365.26,1095.78,3652.6;0,40,80,120},2)
This formula returns the appropriate vacation hours for each employee based
on their anniversary date. With todays date entered as 5/03/07, the
following hire dates give these vacation hours:
Hire Date Vacation Hire Date Vacation
5/2/1994 120 5/3/1994 120
5/2/1995 120 5/3/1995 120
5/2/1996 120 5/3/1996 120
5/2/1997 120 5/3/1997 80
5/2/1998 80 5/3/1998 80
5/2/1999 80 5/3/1999 80
5/2/2000 80 5/3/2000 80
5/2/2001 80 5/3/2001 80
5/2/2002 80 5/3/2002 80
5/2/2003 80 5/3/2003 80
5/2/2004 80 5/3/2004 40
5/2/2005 40 5/3/2005 40
5/2/2006 40 5/3/2006 0
5/2/2007 0 5/3/2007 0
In other words, no vacation time added until appropriate anniversary date.
To explain how it works (and I'm sorry I didn't yesterday - was running
late!)
it subtracts the hire date from todays date, which will return the number of
days an employee has been on the job and then matchs the answer to the
approriate value in the first row of the array. In tabular format, it would
look like this:
0 365.26 1095.78 3652.6
0 40 80 120
HLOOKUP finds the largest value that is less than the lookup value and then
it returns the correct number of vacation days from the second row in the
array.
So, if an employee has worked 4 years, which is about 1,461 days, the
largest value that isn't greater is 1095.78, which gives a vacation time of
80 hours.

Hope this helps!

"Sharon" wrote:

Thanks for the suggestion. I tried this, but it still only gives me the
vacation earned by the year, I need to have it calculate it by the actual
hire date. I need a formula that would also use the month and date so that
the vacation does not appear available until the person's hire date
anniversary. It has been a challenge trying to figure this one out.

--
Any Suggestions Will Be Greatly Appreciated


"Peo Sjoblom" wrote:

With hire date in A1 try this

=IF(A1="","",VLOOKUP(DATEDIF(A1,TODAY(),"y"),{0,0; 1,40;3,80;10,120},2))


try with some test hire dates in A to see if it's what you want


--
Regards,

Peo Sjoblom


"Sharon" wrote in message
...
I have been trying to figure out a formula that will calculate current
vacation hours according to a person's hire date. I have it partly figured
out, but not exactly. I have tried the IF A1 which is my Current Date less
B1
which is my hire date is <365, "0.00", etc. The vacation hrs. are earned
based on 1-2 yrs. = 40 hrs., after 3 yrs.-9yrs. = 80 hrs., after 10yrs.
120
hrs. Does anyone have a formula that will correctly calculate this by hire
date so that the vacation hours do not show until the person's hire date
has
passed? Thanks for ANY Help I can get
--
Any Suggestions Will Be Greatly Appreciated



 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
add a hire date to the end of year (12/31/05) and get Total years Sohoma Knome Excel Discussion (Misc queries) 2 December 28th 05 03:20 PM
date (minus) date = working days diff jjj Excel Discussion (Misc queries) 3 December 6th 05 03:16 PM
From x date To x date you have earned x$ (dates are not the same) RODRODROD Excel Worksheet Functions 5 June 12th 05 03:47 AM
From x date To x date you have earned x$ (dates are not the same) RODRODROD Excel Worksheet Functions 1 June 12th 05 02:32 AM
How can I calculate Vacation Time earned based on length of emplo. Kim Excel Discussion (Misc queries) 2 March 15th 05 08:04 PM


All times are GMT +1. The time now is 03:28 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"