close

I have two non-adjacent cells that I want to average but throw out one
of the numbers if one of them is zero...I used this and it works fine
with adjacent cells but stumped on getting it to work with two
non-adjacent cells. My cells are F3 and K3.

=AVERAGE(IF(B2:C2lt;gt;0,B2:C2,quot; quot;))
CTRL SHIFT ENTER

Thanks for any help I get on this...Hi!

One way:

=IF(COUNT(F3,K3)lt;1,quot;quot;,SUM(F3,K3)/SUMPRODUCT(--(MOD(COLUMN(F3:K3),5)=1),--(F3:K3gt;0)))

Biff

gt; wrote in message ups.com...
gt;I have two non-adjacent cells that I want to average but throw out one
gt; of the numbers if one of them is zero...I used this and it works fine
gt; with adjacent cells but stumped on getting it to work with two
gt; non-adjacent cells. My cells are F3 and K3.
gt;
gt; =AVERAGE(IF(B2:C2lt;gt;0,B2:C2,quot; quot;))
gt; CTRL SHIFT ENTER
gt;
gt; Thanks for any help I get on this...
gt;

Biff wrote:
gt; Hi!
gt;
gt; One way:
gt;
gt; =IF(COUNT(F3,K3)lt;1,quot;quot;,SUM(F3,K3)/SUMPRODUCT(--(MOD(COLUMN(F3:K3),5)=1),--(F3:K3gt;0)))
gt;
gt; Biff
gt;
gt; gt; wrote in message
gt; ups.com...
gt; gt;I have two non-adjacent cells that I want to average but throw out one
gt; gt; of the numbers if one of them is zero...I used this and it works fine
gt; gt; with adjacent cells but stumped on getting it to work with two
gt; gt; non-adjacent cells. My cells are F3 and K3.
gt; gt;
gt; gt; =AVERAGE(IF(B2:C2lt;gt;0,B2:C2,quot; quot;))
gt; gt; CTRL SHIFT ENTER
gt; gt;
gt; gt; Thanks for any help I get on this...
gt; gt;

Thanks that worked!

arrow
arrow
    全站熱搜
    創作者介紹
    創作者 software 的頭像
    software

    software

    software 發表在 痞客邦 留言(0) 人氣()