Solved IF Statement using dates

January 13, 2010 at 09:53:29
Specs: Windows XP

I am trying to use an IF statement that contains a
date and have not had success. What I want is if
the date in A1 is greater than 06/01/2009 then
provide a response of 1; if not then "". The data
in A1 is converted as a date.

See More: IF Statement using dates

Report •


✔ Best Answer
January 13, 2010 at 10:50:32

You could also do something like:

=IF(A1>DATEVALUE("6/1/2009"),1,"")

MIKE

http://www.skeptic.com/



#1
January 13, 2010 at 09:56:29

With todays date in A1,
putting this in B1 work for me:

=IF(A1>6/01/2009,1,"")

MIKE

http://www.skeptic.com/


Report •

#2
January 13, 2010 at 10:08:09

Thanks for the response. It worked for that format, however it is
not working on the dates that would be less than that date. It is
still placing a 1 rather than leaving it blank.

Report •

#3
January 13, 2010 at 10:48:04

Your correct, because Excel is not reading the 06/01/2009 as a date.
Put 06/01/2009 into a cell and then do the compare and it will work.

MIKE

http://www.skeptic.com/


Report •

Related Solutions

#4
January 13, 2010 at 10:50:32
✔ Best Answer

You could also do something like:

=IF(A1>DATEVALUE("6/1/2009"),1,"")

MIKE

http://www.skeptic.com/


Report •

#5
January 13, 2010 at 12:03:37

That did the trick! Thanks for your help. It was driving me crazy.

Report •


Ask Question