Dynamic Substract

Super Contributor

Hello Everyone,

 I would like the number in cell C2 to decrease every time I add a number to the whole of the column C. I would like for any number I enter into the B column to be subtracted automatically from the C2 cell every time a new number is written.

Screenshot (6486).png


What formula should i write?


Please help..??


Here is a attached file...


9 Replies

@Zan_Hanifee The most basic approach would be to enter in C3:


and drag down.

Sir! is it possible to automatic change in C2 when we enter number in B2?

@Zan_Hanifee Not sure what you mean but perhaps like in the picture below??




I think you want to do this row by row. I would not recommend that: you would not have a history of changes, and it would be very difficult to correct mistakes.

But if you really want it, you could use the Worksheet_Change event procedure. See the attached version (now a .xlsm workbook)

best response confirmed by Zan_Hanifee (Super Contributor)



Use this formula =$C$2-SUM($B$3:B3). Also, I have attached screenshot for reference.



It helps.
Thank you so much sir.
Thank you so much sir
it worked! Thank you so much sir.


With an up to date version of 365, one could have

= IF(paidBack, 
     SCAN(loanAmount, paidBack, 
          LAMBDA(acc,p, acc-p)),

which grows dynamically