Running total of consecutive numbers

janderson055

New Member
Joined
Feb 7, 2012
Messages
30
I am trying to put together a formula that will count the consecutive "100"s in a row and return that number. For example if the row shows:
95 100 90 100 100 = 2
But I also want it to start over if the last entry isn't 100, i.e.;
95 100 90 100 100 90 = 0

Anybody have a good idea of how I can keep this running total?
Thanks.
 

Excel Facts

Fastest way to copy a worksheet?
Hold down the Ctrl key while dragging tab for Sheet1 to the right. Excel will make a copy of the worksheet.
Code:
      -A-- --B--
  1   Data Count
  2     95     0
  3    100     1
  4     90     0
  5    100     1
  6    100     2

In B2 and copied down,

=IF(A2<>100, 0, SUM(B1, 1))
 
Upvote 0
I have my data in rows instead of columns and can't change it at this point. Also is there a way I can have a running total just in one cell? Instead of having the total in each B column, just have one cell that will count the consecutive values and revert back to 0 once a value other than 100 is entered?
 
Upvote 0
Forgot the part about having my data in rows, I figured that out and have your function working with my data. I still need to find a way to just have the running total in one cell, where it updates with each new value I enter, resetting the count if a number other than 100 is entered.
 
Upvote 0

Forum statistics

Threads
1,203,219
Messages
6,054,216
Members
444,711
Latest member
Stupid Idiot

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top