Using if statements with a date

S

Stonsey

Hia

I want to use a formula which will return a 0, if the date is on or prior to
31 Dec 2004 and a 2 if date entered is on or after 1 January 2005 - Would
love some help on how to do this

Thanks
 
P

Pete_UK

Assuming your date is in A1, try this:

=IF(A1<DATE(2005,1,1),0,2)

Hope this helps.

Pete
 
L

Luke M

=IF(A2<=DATEVALUE("12/31/2004"),0,IF(A2>=DATEVALUE("1/1/2005",2,"No criteria
match"))
 
S

Stefi

dates being in A2, A3, ...
=--(A2>=DATE(2005,1,1))
Regards,
Stefi

„Stonsey†ezt írta:
 
S

Stefi

It was an oversight, I didn't notice that the OP wants 2 on the TRUE branch.

Sorry for the late answer but I've just now realized that my e-mail
notification doesn't work.


--
Regards!
Stefi



„David Biddulph†ezt írta:
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top