Should I be using "IF"

D

Danno

I have one column that I enter weekly numbers in (i.e. Column "E", Rows 1 thru 52). I have another column (i.e. "H" also using Rows 1 thru 52) that I want to have excel total all the numbers up, to give me a "Year to Date" total entered so far. If I've entered values up to week 8 (i.e Column "E" I have numbers entered in Rows 1 thru 8), I want the YTD column to show me the total (i.e. Column "H" Row 8 will show me that total of Column "E" Rows 1 thru 8). I can do that easily. What I'm having trouble with is that I want all rows, in the YTD column to show 'zeros' below the row that has the last entry. There must be a formula to do this (i.e. IF(E9=0,0) @SUME1,E9). Any Help would be appreciated.
 
R

RagDyer

If I understand you, try this:

In H1 enter:
=E1

In H2 enter:
=(E2>0)*(E2+H1)

And drag down to copy.

However, if you should happen to skip a week, or have zero numbers for a
week, this formula will start over from the zero week and give inaccurate
YTD totals.
--

HTH,

RD
==============================================
Please keep all correspondence within the Group, so all may benefit!
==============================================

I have one column that I enter weekly numbers in (i.e. Column "E", Rows 1
thru 52). I have another column (i.e. "H" also using Rows 1 thru 52) that I
want to have excel total all the numbers up, to give me a "Year to Date"
total
entered so far. If I've entered values up to week 8 (i.e Column "E" I have
numbers entered in Rows 1 thru 8), I want the YTD column to show me the
total (i.e. Column "H" Row 8 will show me that total of Column "E" Rows 1
thru 8). I can do that easily. What I'm having trouble with is that I want
all rows, in the YTD column to show 'zeros' below the row that has the last
entry. There must be a formula to do this (i.e. IF(E9=0,0) @SUME1,E9). Any
Help would be appreciated.
 
R

RagDyer

This formula will give you a grace period of one week of 0.
It will however, extend the YTD total one week beyond the last entry.

=(OR(E1>0,E2>0)*(E2+H1))
--

HTH,

RD
==============================================
Please keep all correspondence within the Group, so all may benefit!
==============================================


If I understand you, try this:

In H1 enter:
=E1

In H2 enter:
=(E2>0)*(E2+H1)

And drag down to copy.

However, if you should happen to skip a week, or have zero numbers for a
week, this formula will start over from the zero week and give inaccurate
YTD totals.
--

HTH,

RD
==============================================
Please keep all correspondence within the Group, so all may benefit!
==============================================

I have one column that I enter weekly numbers in (i.e. Column "E", Rows 1
thru 52). I have another column (i.e. "H" also using Rows 1 thru 52) that I
want to have excel total all the numbers up, to give me a "Year to Date"
total
entered so far. If I've entered values up to week 8 (i.e Column "E" I have
numbers entered in Rows 1 thru 8), I want the YTD column to show me the
total (i.e. Column "H" Row 8 will show me that total of Column "E" Rows 1
thru 8). I can do that easily. What I'm having trouble with is that I want
all rows, in the YTD column to show 'zeros' below the row that has the last
entry. There must be a formula to do this (i.e. IF(E9=0,0) @SUME1,E9). Any
Help would be appreciated.
 
D

Danno

RagDyer

Worked like a charm. Probably looked like a dumb question. Thanx for the help.

Danno
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top