Summation Formula

raj_sidhu2008

New Member
Joined
Jan 20, 2023
Messages
1
Office Version
  1. 365
Platform
  1. Windows
Hello,

I am new to Excel. Can someone kindly advise me the formula for below? I am trying to have a running total of the values in column C by adding B and subtracting A. However, I run into a problem when the cell in C is empty and Excel treats it as "0" and starts returning incorrect values. If the cell is '0', I want Excel to consider the value in the cell one above. Please help.

Capture.JPG
 

Excel Facts

Easy bullets in Excel
If you have a numeric keypad, press Alt+7 on numeric keypad to type a bullet in Excel.
You could use a formula like the below but it would fail if there were 2 blank rows in column C,
=if(C2="",C1+B2-A2,C2+B2-A2)

I would instead use the second formula below
In top row have =C1+B1-A1
In other rows have =D1+C2+B2-A2 to give a running total
 
Upvote 0
I don't understand why your running total suddenly drops to the 62k.
Ignoring that see if this is what you had in mind.

20230120 Running total balance raj_sidhu2008.xlsx
ABC
1DrCrBalance
20/Bal3,317,183.80
350,000.003,367,183.80
45,000.003,362,183.80
55,000.003,357,183.80
6
75,000.003,362,183.80
8
9300.003,361,883.80
10600.003,361,283.80
Data
Cell Formulas
RangeFormula
C3:C10C3=IF(COUNT(A3:B3)=0,"", IF(C2="", INDEX(C$1:C2,MATCH(2,1/(C$1:C2<>""),1),0)+B3-A3, C2+B3-A3 ) )
 
Upvote 0

Forum statistics

Threads
1,214,651
Messages
6,120,744
Members
448,989
Latest member
mariah3

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