A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Excel » Worksheet Functions
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Calculate Months to Determine Length of Service



 
 
Thread Tools Display Modes
  #1  
Old April 9th, 2009, 08:47 PM posted to microsoft.public.excel.worksheet.functions
WilliamsDeLisle
external usenet poster
 
Posts: 10
Default Calculate Months to Determine Length of Service

I need to be able to input a beginning employment date, i.e., 10/12/1994 and
calculate the number of months between this date and the current date to
determine the amount of vacation earned per month to be used in an IF formula.

EXAMPLE: Start Date 06/13/85 current date 04/9/09 = How Many Months
IF Statement would be If 0-60 months 8 Hours accrued each month, if 61-120
months 10 hours accrued each month, If 121-180 months 12 hours accrued each
month.


  #2  
Old April 9th, 2009, 08:56 PM posted to microsoft.public.excel.worksheet.functions
Gary''s Student
external usenet poster
 
Posts: 7,584
Default Calculate Months to Determine Length of Service

if A1 contains:
6/13/1985
and B1 contains:
4/9/2009

Then:
=(YEAR(B1)-YEAR(A1))*12+MONTH(B1)-MONTH(A1)
displays 286 as the number of months
--
Gary''s Student - gsnu200845


"WilliamsDeLisle" wrote:

I need to be able to input a beginning employment date, i.e., 10/12/1994 and
calculate the number of months between this date and the current date to
determine the amount of vacation earned per month to be used in an IF formula.

EXAMPLE: Start Date 06/13/85 current date 04/9/09 = How Many Months
IF Statement would be If 0-60 months 8 Hours accrued each month, if 61-120
months 10 hours accrued each month, If 121-180 months 12 hours accrued each
month.


  #3  
Old April 9th, 2009, 09:13 PM posted to microsoft.public.excel.worksheet.functions
Sean Timmons
external usenet poster
 
Posts: 1,722
Default Calculate Months to Determine Length of Service

k.. here's the most accurate I can get...

Assuming the start date is in cell A1.

This formula will come back as FALSE if the employee is over 15 years. To
fix that, put, sa: ,12,14 instead of just ,12 at the end.......

=IF((DATE(YEAR(A1),MONTH(A1),DAY(A1)))(DATE(YEAR( TODAY()-5),MONTH(TODAY()),DAY(TODAY()))),8,IF((DATE(YEAR(A 1),MONTH(A1),DAY(A1)))(DATE(YEAR(TODAY()-10),MONTH(TODAY()),DAY(TODAY()))),10,IF((DATE(YEAR (A1),MONTH(A1),DAY(A1)))(DATE(YEAR(TODAY()-15),MONTH(TODAY()),DAY(TODAY()))),12)))

"WilliamsDeLisle" wrote:

I need to be able to input a beginning employment date, i.e., 10/12/1994 and
calculate the number of months between this date and the current date to
determine the amount of vacation earned per month to be used in an IF formula.

EXAMPLE: Start Date 06/13/85 current date 04/9/09 = How Many Months
IF Statement would be If 0-60 months 8 Hours accrued each month, if 61-120
months 10 hours accrued each month, If 121-180 months 12 hours accrued each
month.


  #4  
Old April 9th, 2009, 09:14 PM posted to microsoft.public.excel.worksheet.functions
Alan
external usenet poster
 
Posts: 431
Default Calculate Months to Determine Length of Service

or

=(YEAR(NOW())-YEAR(A1))*12-MONTH(A1)+MONTH(NOW())

"Gary''s Student" wrote in message
...
if A1 contains:
6/13/1985
and B1 contains:
4/9/2009

Then:
=(YEAR(B1)-YEAR(A1))*12+MONTH(B1)-MONTH(A1)
displays 286 as the number of months
--
Gary''s Student - gsnu200845


"WilliamsDeLisle" wrote:

I need to be able to input a beginning employment date, i.e., 10/12/1994
and
calculate the number of months between this date and the current date to
determine the amount of vacation earned per month to be used in an IF
formula.

EXAMPLE: Start Date 06/13/85 current date 04/9/09 = How Many Months
IF Statement would be If 0-60 months 8 Hours accrued each month, if
61-120
months 10 hours accrued each month, If 121-180 months 12 hours accrued
each
month.



  #5  
Old April 9th, 2009, 09:31 PM posted to microsoft.public.excel.worksheet.functions
Sean Timmons
external usenet poster
 
Posts: 1,722
Default Calculate Months to Determine Length of Service

Careful though... If the day of month of today is less than day of month of
hire date, it's really 5 months and, say, 20 days, not 6 months. Depends on
the level of accuracy the OP needs, of course...

"Alan" wrote:

or

=(YEAR(NOW())-YEAR(A1))*12-MONTH(A1)+MONTH(NOW())

"Gary''s Student" wrote in message
...
if A1 contains:
6/13/1985
and B1 contains:
4/9/2009

Then:
=(YEAR(B1)-YEAR(A1))*12+MONTH(B1)-MONTH(A1)
displays 286 as the number of months
--
Gary''s Student - gsnu200845


"WilliamsDeLisle" wrote:

I need to be able to input a beginning employment date, i.e., 10/12/1994
and
calculate the number of months between this date and the current date to
determine the amount of vacation earned per month to be used in an IF
formula.

EXAMPLE: Start Date 06/13/85 current date 04/9/09 = How Many Months
IF Statement would be If 0-60 months 8 Hours accrued each month, if
61-120
months 10 hours accrued each month, If 121-180 months 12 hours accrued
each
month.




  #6  
Old April 9th, 2009, 09:36 PM posted to microsoft.public.excel.worksheet.functions
Rick Rothstein[_2_]
external usenet poster
 
Posts: 2,013
Default Calculate Months to Determine Length of Service

How do you count your months? For example, how many months do you think are
between these date ranges?

1/1/2008 - 5/1/2008

1/1/2008 - 5/31/2008

1/31/2008 - 5/1/2008

--
Rick (MVP - Excel)


"WilliamsDeLisle" wrote in
message ...
I need to be able to input a beginning employment date, i.e., 10/12/1994
and
calculate the number of months between this date and the current date to
determine the amount of vacation earned per month to be used in an IF
formula.

EXAMPLE: Start Date 06/13/85 current date 04/9/09 = How Many Months
IF Statement would be If 0-60 months 8 Hours accrued each month, if
61-120
months 10 hours accrued each month, If 121-180 months 12 hours accrued
each
month.



  #7  
Old April 9th, 2009, 09:53 PM posted to microsoft.public.excel.worksheet.functions
WilliamsDeLisle
external usenet poster
 
Posts: 10
Default Calculate Months to Determine Length of Service



"Rick Rothstein" wrote:

How do you count your months? For example, how many months do you think are
between these date ranges?

1/1/2008 - 5/1/2008 - 4 Months

1/1/2008 - 5/31/2008 - 5 Months

1/31/2008 - 5/1/2008 - 4 Month

--
Rick (MVP - Excel)


"WilliamsDeLisle" wrote in
message ...
I need to be able to input a beginning employment date, i.e., 10/12/1994
and
calculate the number of months between this date and the current date to
determine the amount of vacation earned per month to be used in an IF
formula.

EXAMPLE: Start Date 06/13/85 current date 04/9/09 = How Many Months
IF Statement would be If 0-60 months 8 Hours accrued each month, if
61-120
months 10 hours accrued each month, If 121-180 months 12 hours accrued
each
month.




  #8  
Old April 9th, 2009, 09:55 PM posted to microsoft.public.excel.worksheet.functions
T. Valko
external usenet poster
 
Posts: 15,759
Default Calculate Months to Determine Length of Service

Try this:

A1 = start date

=DATEDIF(A1,NOW(),"m")

--
Biff
Microsoft Excel MVP


"WilliamsDeLisle" wrote in
message ...
I need to be able to input a beginning employment date, i.e., 10/12/1994
and
calculate the number of months between this date and the current date to
determine the amount of vacation earned per month to be used in an IF
formula.

EXAMPLE: Start Date 06/13/85 current date 04/9/09 = How Many Months
IF Statement would be If 0-60 months 8 Hours accrued each month, if
61-120
months 10 hours accrued each month, If 121-180 months 12 hours accrued
each
month.




  #9  
Old April 9th, 2009, 10:10 PM posted to microsoft.public.excel.worksheet.functions
Rick Rothstein[_2_]
external usenet poster
 
Posts: 2,013
Default Calculate Months to Determine Length of Service

I don't understand why the middle range is 5 months whereas the last range
is 4 months. Given the 5 month answer (using half months for rounding I
think), I would have expected the last one to be 3 months... can you explain
how you are rounding?

--
Rick (MVP - Excel)


"WilliamsDeLisle" wrote in
message ...


"Rick Rothstein" wrote:

How do you count your months? For example, how many months do you think
are
between these date ranges?

1/1/2008 - 5/1/2008 - 4 Months

1/1/2008 - 5/31/2008 - 5 Months

1/31/2008 - 5/1/2008 - 4 Month

--
Rick (MVP - Excel)


"WilliamsDeLisle" wrote in
message ...
I need to be able to input a beginning employment date, i.e., 10/12/1994
and
calculate the number of months between this date and the current date
to
determine the amount of vacation earned per month to be used in an IF
formula.

EXAMPLE: Start Date 06/13/85 current date 04/9/09 = How Many Months
IF Statement would be If 0-60 months 8 Hours accrued each month, if
61-120
months 10 hours accrued each month, If 121-180 months 12 hours accrued
each
month.





  #10  
Old April 9th, 2009, 10:43 PM posted to microsoft.public.excel.worksheet.functions
WilliamsDeLisle
external usenet poster
 
Posts: 10
Default Calculate Months to Determine Length of Service

I made a mistake - sorry - You are correct the first two are 5 months the
last on is 3 months.

"Rick Rothstein" wrote:

I don't understand why the middle range is 5 months whereas the last range
is 4 months. Given the 5 month answer (using half months for rounding I
think), I would have expected the last one to be 3 months... can you explain
how you are rounding?

--
Rick (MVP - Excel)


"WilliamsDeLisle" wrote in
message ...


"Rick Rothstein" wrote:

How do you count your months? For example, how many months do you think
are
between these date ranges?

1/1/2008 - 5/1/2008 - 4 Months

1/1/2008 - 5/31/2008 - 5 Months

1/31/2008 - 5/1/2008 - 4 Month

--
Rick (MVP - Excel)


"WilliamsDeLisle" wrote in
message ...
I need to be able to input a beginning employment date, i.e., 10/12/1994
and
calculate the number of months between this date and the current date
to
determine the amount of vacation earned per month to be used in an IF
formula.

EXAMPLE: Start Date 06/13/85 current date 04/9/09 = How Many Months
IF Statement would be If 0-60 months 8 Hours accrued each month, if
61-120
months 10 hours accrued each month, If 121-180 months 12 hours accrued
each
month.






 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 02:03 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.