Subtract cells based on previous and current values of other cells

tHE fLY

New Member
Joined
Jul 8, 2014
Messages
31
Hey everyone,

i have the following problem... It seems complex and I'm not sure how to get my formula to work

I want the following to happen

If column a has an amount then column c will have an amount
And that amount will subtract column b.. For each blank in cell a... I want column c cells to subtract the previous blank cells that have values in column B to be subtracted from column c cell...

example below.

Column a | column b | column c
100,000. |. 1000. | 17,000 (cell C1- B1)
Blank. |. 1000. |. Blank
Blank. |. 1000. |. Blank
100,000. |. 1000. | 31,000. (Cell C4 - sum(Cell B2:B4)
Blank. |. 1000. | blank.
100,000. |. 1000. |35,000. (Cell C6 -sum(B5:B6)

Thanks for your help!
 
Last edited:

Excel Facts

Enter current date or time
Ctrl+: enters current time. Ctrl+; enters current date. Use Ctrl+: Ctrl+; Enter for current date & time.
Make sure to have column headers in row 1 and data starting in row 2.
Enter in D2: =IF(C2="","",SUM($C$2:C2)-SUM($B$2:B2)-SUM($D$1:D1))
Copy downwards.
 
Last edited:
Upvote 0

Forum statistics

Threads
1,215,884
Messages
6,127,567
Members
449,385
Latest member
KMGLarson

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