Home |
Search |
Today's Posts |
#7
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
It is no more specific than yours. Plug 2005 into a cell, and it is a simple
change =IF(YEAR(D2)=$M$1,$M$1,"No") -- __________________________________ HTH Bob "Paperback Writer" wrote in message ... I plug in the formula, and I still get a problem IF(AND((D2DATE(2004,12,31),(D2<DATE(2006,1,1)),"2 005","NO") Is this the corrected formula? I can't use yours because it is year specific. I need variants that will allow me to specify dates. Thanks!! "John C" wrote: You have too many parentheses: IF(AND((D2DATE(2004,12,31),(D2<DATE(2006,1,1)),"2 005","NO") but a better formula might be: =IF(YEAR(D2)=2005,2005,"NO") -- John C "Paperback Writer" wrote: Can someone help with my logic? I can't seem to figure this out. I want it to say "2005" if the date is between 12/31/2004 and 01/01/2006. I keep getting an error. Here is my formula. IF((AND(D2DATE(2004,12,31)),(D2<DATE(2006,1,1))), "2005","NO") |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Date Comparison and IF statement | Excel Worksheet Functions | |||
how do I write the date in an if statement | Excel Worksheet Functions | |||
How can I use a date in an IF/AND statement? | Excel Discussion (Misc queries) | |||
If statement with date | Excel Discussion (Misc queries) | |||
Date in an IF statement | Excel Worksheet Functions |