Excel 2007 formulas

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am trying to write a formula for a class where we have to take todays date
(using the today function) and subtract it from a set of dates to see if the
people are over 18 or not. Im having trouble with the TODAY function.

every time i try to use it the T turns in to a lower cass letter and it says
that the function is invalad. any sugestions!
 
I don't use Excel 2007 but this will work:

A1 = birth date

=DATEDIF(A1,TODAY(),"Y")

That will return the *full* years of age.

Or, to test for the age being >=18 *full* years:

=DATEDIF(A1,TODAY(),"Y")>=18

This will return either TRUE or FALSE
 
That formula will say someone is 18 if they are born any time in 1989,
including those who won't be 18 until the end of this year. DATEDIF would
be a better bet.
 
I am trying to write a formula for a class where we have to take todays
date
(using the today function) and subtract it from a set of dates to see if
the
people are over 18 or not. Im having trouble with the TODAY function.

every time i try to use it the T turns in to a lower cass letter and it
says
that the function is invalad. any sugestions!

Your description of what is happening is a little vague, but let me hazard a
guess... are you forgetting to put the open/close parentheses on the end of
the TODAY function (they are required)?

Rick
 
Rick Rothstein (MVP - VB) said:
Your description of what is happening is a little vague, but let me hazard
a guess... are you forgetting to put the open/close parentheses on the end
of the TODAY function (they are required)?

Rick

Doing that would/should cause a #NAME? error. I've never experienced what
the OP describes. Is it maybe a new behavior to Excel 2007?
 
I am trying to write a formula for a class where we have to take todays
Doing that would/should cause a #NAME? error. I've never experienced what
the OP describes. Is it maybe a new behavior to Excel 2007?

It does cause a #NAME? error which is sort of why I said his description of
what was happening was "vague" (he didn't mention **any** error). The reason
I made the guess I did is if the OP had typed in =Today (only capitalizing
the "T"), then after the error was generated, if you looked in the formula
bar, the equation had become =today (the "T" had turned into lower case as
the OP reported). I did say it was a guess, but if the OP had left the
parentheses off, what he described is sort of what happens (although, of
course, it isn't the main thing that happens).

Rick
 
Interesting!
If I try to enter =Today, without the parentheses, then I get =TODAY (all in
upper case) rather than turning the capital T to lower case. I do, of
course, also get the #NAME error.
 
Very interesting... I just retried it in XL2003 and XL2007... what seems to
happen is the first way you type it in is the way it will make it from then
on (for the rest of the session) no matter how you change the casing. Try
this, close down your version of Excel and then re-open it. Type this into a
cell....

=ToDaY

type it just like I did above. Now, go to another cell and type this in...

=today

Hit the enter key to commit it and then re-select the cell and look at the
formula bar... the lower case spelling should have changed to the casing you
used the very first time. So, my first observation was not correct because I
remember I had typed in =today first and then retried it with the first
letter capitalize. Anyway, this means we don't know what the OP's problem
really is (until he gives us more information).

Rick
 
Back
Top