if formula error

Hi expert's excel 2007

I am trying to work out the following formula

=if(b15="",if(c15="","No",if(c15="",newtworkdays(b15,e11,public holidays))))

Where public holidays is a named range...
Who is Participating?

Finance AnalystCommented:
The blank check of B15 & C15 can be combined in and AND

=IF(AND(B15="",C15=""),"",NETWORKDAYS(...

You don't have an option for when both are populated.

You have 4 scenarios that need to be covered.
B & C Blank - covered above -> Blank
B Blank, C populated
B populated, C Blank
B & C populated

Thanks
Rob H
0

Commented:
you have an extra "w" in the NETWORKDAYS function before the "t".  Remove it.
0

Author Commented:
Hi that's a typo on my part when asking the question...
0

Commented:
Then, what is the issue?  The formula enters correctly otherwise, but not sure what you are asking?
0

Author Commented:
The issue is I am getting false as oppsed to 46 days
0

Commented:
You have 2 different outcomes in your formula for when C15=""...

Can you explain, with words what you want the formula to check and do please?
0

Finance AnalystCommented:
B15 is Blank leads to check C15

B15 is not Blank does not have an option

C15 is blank gives "No"

C15 is not Blank checks if C15 is blank (already checked!!)

C15 is not blank does NETWORKDAYS calculation.

Thanks
Rob H
0

Finance AnalystCommented:
BTW to avoid typos like you had in the question, you can copy and paste from excel to the Question. To copy the formula, highlight the formula in the formula bar and press Ctrl + C; then you can paste into question text.
0

Author Commented:
Nbvc

in words...
if b15 is blank and c15 is blank then return no date otherwise if c15 is blank and b15 has a date then networkdays calculation.
0

Author Commented:
Apologies. ..for typo using iphone...
0

Commented:
Try:

=IF(C15="",IF(B15<>"",NETWORKDAYS(B15,E11,public holidays),"No"),"No")
0

Author Commented:
Excellent all
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.