Excel IF statement problem

  • Thread starter Thread starter ncm022401
  • Start date Start date
N

ncm022401

I have this formula:
=IF(AND(ISBLANK(D5),ISBLANK(E5),"",F4-D5+E5)

It works when there is either a number in D5 or E5, but if there is n
numbers it will not carry the number from F4, can you help me please.

Sarah Clemon
 
Why are you using the IF(AND statement at all? If indeed you want the value
from F4 as the result if
both D5 and E5 are blank and if they are not blank you want F4-D5+E5? Then
just use

=F4-D5+E5



--


For everyone's benefit keep the discussion in the newsgroup.

Regards,

Peo Sjoblom
 
I know next to nothing about Excel, other than it's AWSOME! If m
suggestion is way too "novice" please forgive me. If you're workin
with numbers only, maybe you could just say
=IF(AND(D5=0,E5=0),"",F4-D5+E5)

or something like tha
 
Sarah,

If you don't want the formula cell not to show 0 with no data at all then
try:

=IF(N(SUM(D5:F5)),F5-D5+E5,"")

HTH

Sandy
 
Back
Top