Excel doesn't support a null value. What's the
2nd equation that produces an error?
=IF(F8+H8+J8+L8+N8=0,0,(G8+I8+K8+M8+O8)/(IF(G8>0,1,0)+IF(I8>0,1,0)+IF(K8>0,1,0)+IF(M8>0,1,0)+IF(O8>0,1,0)))
There are times when any or all of F8+H8+J8+L8+N8
could have a "" blank in them
Thanks
Mike, the SUM() function ignores text. Try this:
=IF(SUM(F8,H8,J8,L8,N8)=0,0,SUM(G8,I8,K8,M8,O8)/(IF(G8>0,1,0)+IF(I8>0,1,0)+IF(K8>0,1,0)+IF(M8>0,1,0)+IF(O8>0,1,0)))
BTW, you can simply this formula in other ways too!
Try this:
=IF(SUM(F8,H8,J8,L8,N8),SUM(G8,I8,K8,M8,O8)/((G8>0)+(I8>0)+(K8>0)+(M8>0)+(O8>0)),0)
If you want the true zero values counted in the denominator, use
=IF(SUM(F8,H8,J8,L8,N8)>0,IF(SUM(G8,I8,K8,M8,O8)>0,SUM(G8,I8,K8,M8,O8)/COUNT(G8,I8,K8,M8,O8),0),0)
If not, use
=IF(SUM(F8,H8,J8,L8,N8)>0,IF(SUM(G8,I8,K8,M8,O8)>0,SUM(G8,I8,K8,M8,O8)/(COUNTIF(G8,">0")+COUNTIF(I8,">0")+COUNTIF(K8,">0")+COUNTIF(M8,">0")+COUNTIF(O8,">0")),0),0)
Aladin