Need help with IF(AND) function

wpavone

New Member
Joined
Apr 1, 2011
Messages
27
:confused: I'm working on a project scheduling tool. L7 contains a start date and M7 contains a finish date. K1 contains the current day's date. Progress towards completion is measured as: Green if L7 is greater than 14 days prior to K1; Yellow if L7 is between 14 days greater and today's date; Red if L7 is past today's date; Blue once M7 is entered. No value is returned if L7 is blank. So far I have the following nested IF statement: =IF(AND(M7="",L7<$K$1),"R",IF(L7="","",IF(M7<=$K$1,"G",IF(M7>0,"B",IF(SUM(M7-L7<14),"Y",""))))). As written, this is returning a value of Red when L7 is blank. I've re-written this multiple different ways but I just can't figure out how to write it so the values return correctly. Help! Any suggestions will be appreciated.
 

Excel Facts

Spell Check in Excel
Press F7 to start spell check in Excel. Be careful, by default, Excel does not check Capitalized Werds (whoops)
Hi and welcome to the board,

Does something like this work?

=IF(M7<>"","Blue",LOOKUP(L7-K1,{-10000,"Green";-14,"Yellow";1,"Red"}))
 
Upvote 0

Forum statistics

Threads
1,224,586
Messages
6,179,728
Members
452,939
Latest member
WCrawford

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top