Home |
Search |
Today's Posts |
#1
|
|||
|
|||
IF Statement
I am trying to create an "IF" statement whose value is contingent upon a
range of cells. Basically, I have 5 cells with 5 different dates. I also have a cell which is designated to search the 5 date cells ("IF" statement) and if one of the cells has a date less than or equal to today's date...I want my "IF" statement to notify me. Right now, I can only search one cell. Any suggestions? |
#2
|
|||
|
|||
One way:
=IF(COUNTIF(A1:A5,"<=" & TODAY())0,"Be notified", "") In article , "Brent" wrote: I am trying to create an "IF" statement whose value is contingent upon a range of cells. Basically, I have 5 cells with 5 different dates. I also have a cell which is designated to search the 5 date cells ("IF" statement) and if one of the cells has a date less than or equal to today's date...I want my "IF" statement to notify me. Right now, I can only search one cell. Any suggestions? |
#3
|
|||
|
|||
If your dates are in a range like A1:A5 you could use
=sumproduct(--(A1:A5<=today())) And it will return the number of days in the range that are less than equal to today's date so if it says 0 there aren't any otherwise there are. Another way would be to use =if(or(a1<=today(),a2<=today(),a3<=today(),a4<=tod ay(),a5<=today()),"Yes","") This will say Yes if there are any days in the range less than or equal to today. If there aren't any it would just remain blank. HTH "Brent" wrote: I am trying to create an "IF" statement whose value is contingent upon a range of cells. Basically, I have 5 cells with 5 different dates. I also have a cell which is designated to search the 5 date cells ("IF" statement) and if one of the cells has a date less than or equal to today's date...I want my "IF" statement to notify me. Right now, I can only search one cell. Any suggestions? |
#4
|
|||
|
|||
Perfect....The "COUNTIF" threw me off a bit, but it worked...Thanks.
"JE McGimpsey" wrote: One way: =IF(COUNTIF(A1:A5,"<=" & TODAY())0,"Be notified", "") In article , "Brent" wrote: I am trying to create an "IF" statement whose value is contingent upon a range of cells. Basically, I have 5 cells with 5 different dates. I also have a cell which is designated to search the 5 date cells ("IF" statement) and if one of the cells has a date less than or equal to today's date...I want my "IF" statement to notify me. Right now, I can only search one cell. Any suggestions? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How to calculate a sum as one outcome of an IF statement | Excel Worksheet Functions | |||
What statement to use? | Excel Worksheet Functions | |||
How do I fix a circular reference in a financial statement? | Excel Discussion (Misc queries) | |||
7+ nested if statement? | Excel Worksheet Functions | |||
Statement | Excel Worksheet Functions |