close

I am trying to compose an IF function to automatically move hours around a
spread sheet. There are 5-10 areas designated by 2 letter abbreviations and
the hours need to be added to those respective areas. This is what I have so
far,

=IF(E2=quot;exquot;, D2)

is there anyway to make where is says E2 to be able to read a column
section, say E2 through E10 and wherever there is the quot;exquot; in that column it
will add to the cell the formula is in? Any help would be appreciated. Jason

Hi!

See if this is what you had in mind:

=SUMIF(E2:E10,quot;exquot;,D210)

It will sum the values in D210 if the corresponding cell in E2:E10 equals
quot;exquot;.

Biff

quot;Jasonquot; gt; wrote in message
...
gt;I am trying to compose an IF function to automatically move hours around a
gt; spread sheet. There are 5-10 areas designated by 2 letter abbreviations
gt; and
gt; the hours need to be added to those respective areas. This is what I have
gt; so
gt; far,
gt;
gt; =IF(E2=quot;exquot;, D2)
gt;
gt; is there anyway to make where is says E2 to be able to read a column
gt; section, say E2 through E10 and wherever there is the quot;exquot; in that column
gt; it
gt; will add to the cell the formula is in? Any help would be appreciated.
gt; Jason
Unfortunately not. I need it to read the section and wherever the quot;exquot; is it
will take the number in the previous column and add it to the total only. I
am using this to track project hours for the company I work for. I figured
out this much last night for one section:

=SUM(C6-D6) (IF(E2=quot;csmtquot;, D2)) (IF(E3=quot;csmtquot;, D3)) (IF(E4 =quot;csmtquot;, D4)) (IF(E5=quot;csmtquot;, D5))

so wherever csmt shows up it will take the number in the previous column and
add it to this total. I can keep nesting this formula but I was wondering if
there is an easier way to do it besides typing each cell in manually. Mainly
because there is aprox. 1500 employees in each section and the formula will
become quite huge.

quot;Biffquot; wrote:

gt; Hi!
gt;
gt; See if this is what you had in mind:
gt;
gt; =SUMIF(E2:E10,quot;exquot;,D210)
gt;
gt; It will sum the values in D210 if the corresponding cell in E2:E10 equals
gt; quot;exquot;.
gt;
gt; Biff
gt;
gt; quot;Jasonquot; gt; wrote in message
gt; ...
gt; gt;I am trying to compose an IF function to automatically move hours around a
gt; gt; spread sheet. There are 5-10 areas designated by 2 letter abbreviations
gt; gt; and
gt; gt; the hours need to be added to those respective areas. This is what I have
gt; gt; so
gt; gt; far,
gt; gt;
gt; gt; =IF(E2=quot;exquot;, D2)
gt; gt;
gt; gt; is there anyway to make where is says E2 to be able to read a column
gt; gt; section, say E2 through E10 and wherever there is the quot;exquot; in that column
gt; gt; it
gt; gt; will add to the cell the formula is in? Any help would be appreciated.
gt; gt; Jason
gt;
gt;
gt;

This formula will do exactly what your (long-winded) one does:

=C6-D6 SUMIF(E2:E5,quot;csmtquot;,D25)

Perhaps you can see how to modify it for larger ranges.

Hope this helps.

Pete

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

software

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