reset to zero

  • Thread starter Thread starter baldyheed
  • Start date Start date
B

baldyheed

i need to keep a running total of a random series of numbers in a column
and when a zero appears i need it reset to zero and start counting again
from the next number, hope i explained this as easy as possible? thanks
for any help.
 
Hi!

Assume the numbers are in the range A1:An

Enter this formula in B1:

=(A1>0)*1

Enter this formula in B2 and copy down as needed:

=IF(A2=0,0,B1+1)

Biff
 
Assuming that your numbers are in column A, in cell B1 put
=A1

in cell B2 put
=if(A2=0,0,B1+A2)

and formula-copy that to the end of your numbers.
 
reset to zero and start counting again

I thought they wanted a count.

Well, either way we got it covered!

Biff

"Bryan Hessey" <[email protected]>
wrote in message
 

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

Back
Top