View Single Post
  #5   Report Post  
Ron Rosenfeld
 
Posts: n/a
Default

On Thu, 30 Jun 2005 22:43:25 +0200, "DzEK" wrote:

the point is to calculate the somebodies working period in firm!
i know when somebody arrive and left the firm.
so i want "automatically" know how many years, months and dates did someb.
spend on work...

http://www.cpearson.com/excel/datedif.htm
is excellent link, but always get the error when copy/paste in my
workbook.

don't know what to do!!

can you explain me how to solve the problem, step by step, please
from the beginning, :)
mean, where what, syntax etc.

many thans


As I wrote, years and months are not precise.

One year may have 365 days, or 366 days.

One month may have 28, 29, 30 or 31 days.

So if you want to know EXACTLY how long someone has worked, you can use days or
weeks.

So the formula would be StartDate-EndDate (and format the result as General)

If you want to know approximately, in years, months and days, you can use the
DATEDIF function:

=DATEDIF(StartDate,EndDate,"y")& " years, "&
DATEDIF(StartDate,EndDate,"ym")&" Months, and "&
DATEDIF(StartDate,EndDate,"md") & " Days"

But this formula, although usually reasonably close, can give some strange
results depending on your StartDate and EndDate.

For example:

StartDate: 1/31/2004
EndDate: 3/1/2005

Result: 1 years, 1 Months, and -2 Days

So if you have better definitions of how you want to define month and year, let
us know.


--ron