View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.misc
Sherry Sherry is offline
external usenet poster
 
Posts: 116
Default Update Upon Opening based on DATEIF NOW()

So whatever month is in the A1 cell is telling my whole DATEIF() formula how
many days to use to count my days in a month?? It seems to me that it would
change each time I pasted the formula in a different cell next to a different
date. I guess I'm missing something. Can you offer advice on a better
formula. Any help is greatly appreciated.

However, right before I hit "post", I just checked my results. None were
wrong. I put in your dates and did not get the results you got. I'm using
Excel 2007. Maybe you're speaking of a different version and this one
actually works right!! :)
--
sherry


"JE McGimpsey" wrote:

Well, kinda...

DATEDIF() uses the length of the first month to determine month lengths,
so that leads to some bizarre results:

Assume A1 = 1/31/2007

then some results will look like:

2/27/2009 2 years, 0 months, 27 days
2/28/2009 2 years, 0 months, 28 days
3/1/2009 2 years, 1 months, -2 days
3/2/2009 2 years, 1 months, -1 days
3/3/2009 2 years, 1 months, 0 days
3/4/2009 2 years, 1 months, 1 days
3/5/2009 2 years, 1 months, 2 days

likewise

4/29/2009 2 years, 2 months, 29 days
4/30/2009 2 years, 2 months, 30 days
5/1/2009 2 years, 3 months, 0 days
5/2/2009 2 years, 3 months, 1 days
5/3/2009 2 years, 3 months, 2 days



In article ,
sherry wrote:

Hi All,

If I enter, for example, a birth date in column A1 and the below formula in
another column, I understand the result will be someone's age in years,
months, and days. My question is: Tomorrow, when I open my file, will my
result show one more day added to the "days" number? Thanks for your time.

=DATEDIF(A1,NOW(),"y") & " years, " & DATEDIF(A1,NOW(),"ym") & " months, " &
DATEDIF(A1,NOW(),"md") & " days"