Hi everybody, i want to count every number except 0 and 2, and everytime after 2 apears i want to start counting again.
Hi everybody, i want to count every number except 0 and 2, and everytime after 2 apears i want to start counting again.
Try attached
Please Login or Register to view this content.
Last edited by Ochimus; 11-27-2020 at 09:26 PM.
Try in C2:
Drag downPlease Login or Register to view this content.
Quang PT
yes, but u forget that i still got 0 number in the A column
Which helper are you addressing?
A 'thank you' might have been nice to start with ...
Ali
Enthusiastic self-taught user of MS Excel who's always learning!
Don't forget to say "thank you" in your thread to anyone who has offered you help.
You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.
Forum Rules (updated August 2023): please read them here.
Sorry, i was talking with bebo021999. I cant use the formula in C2 because i need to put it from C1, and if i start from there it will not work because i have a 0 in A1. I need to use this formula for some columns and in all of them i have more than one 0 in the first rows.
Pl see file. ARRAY formula in E3 then copy down.
=IF(AND(A3<>0,A3<>2),SUM(--((INDEX($A$2:$A3,IFERROR(MATCH(2,--1/($A$2:$A3=2),1)+1,ROW($A$2))):$A3)>0)),"")
To enter ARRAY formula
Copy and paste the formula in cell
Press F2
Press Ctrl+Shift+Enter together
Excel covers the formula with {}.
Pl note
Array formula should be confirmed with Ctrl+Shift+Enter keys together.
If answere is satisfactory press * to add reputation.
Thank you kvsrinivasamurthy, is exactly what y need.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks