Solved I have 4 different dates and I want to apply IF condition

October 12, 2017 at 07:33:54
Specs: Windows 7
I have 4 different dates in 4 cells and I want to apply IF condition with networkdays that if 1st cell is empty takes the second and calculates networkdays if second and also empty calculates with third one. I apply the formula =IF(AW5="",NETWORKDAYS(AT5,AV5),IF(AV5="",NETWORKDAYS(AT5,AU5),NETWORKDAYS(AT5,AU5))) but the issue is that its giving me negative days because 1st 2 cells are empty and its not fulfilling the condition. Please help

See More: I have 4 different dates and I want to apply IF condition

Reply ↓  Report •

#1
October 12, 2017 at 08:02:28
✔ Best Answer
You might try reversing your logic.
Instead of checking if the cell is Blank, check to see if it is NOT Blank
and let the Nested IF statements cascade thru the formula, something like:

=IF(AW5<>"",NETWORKDAYS(AT5,AW5),IF(AV5<>"",NETWORKDAYS(AT5,AV5) etc. etc.

If AW5 is not blank, TRUE, do the NETWORKDAYS calculation
If AW5 IS blank, FALSE, go to the next IF statment
If AV5 is not blank, TRUE, do the NETWORKDAYS calculation
If AV5 IS blank, FALSE, go to the next IF statment

MIKE

http://www.skeptic.com/


Reply ↓  Report •

#2
October 12, 2017 at 08:22:54
Perfect!

Its working

Thanks Mike :)


Reply ↓  Report •
Related Solutions


Ask Question