Excel - Logical Test on Date value

Asked By Sheila on 25-Sep-08 01:50 PM
I'm using the IF function and want the logical test to check whether a date
value is greater than another date; I can do this if I store the 2nd date in
another cell but would like to type directly into the formula. I've tried
B3>01/01/2008 in several different ways and also used the date function as
part of the logical test but it does not return the correct result.

Is there a trick to this or do I have to refer to another cell for dates? No
problem with doing this I just think I should be able to do it 'directly'
Thanks for any help (I'm using 2007 but the same result occurs in 2000)

Chip Pearson replied on 25-Sep-08 02:01 PM
Try using the DATE function to convert year, month, and day to an
actual date. E.g.,

=IF(A1>DATE(2008,11,23),"A1 is greater","A1 is not greater")

Chip Pearson
Microsoft MVP
Excel Product Group
Pearson Software Consulting, LLC
The San Diego Project Group, LLC
(email is on the web site)
USA Central Daylight Time (-5:00 GMT)

On Thu, 25 Sep 2008 10:50:10 -0700, Sheila D