Adding a row but if a cell is blank use an alternate cell

Beh162

Board Regular
Joined
Jan 15, 2015
Messages
130
I'm trying to add the value of cells, but if it's blank I want to use another cell.
105 (A1)106(B1)107108
110(A2)125

What I'm trying to do is add the bottom row (110+125...) but when the cell is blank I need to use the number above it. So in the example it would be 110+125+107+108. Is this possible?
Thanks!
 

Excel Facts

What is =ROMAN(40) in Excel?
The Roman numeral for 40 is XL. Bill "MrExcel" Jelen's 40th book was called MrExcel XL.
If you are using MS 365:
Book1
ABCD
1105106107108
2110125
3
4450
Sheet12
Cell Formulas
RangeFormula
A4A4=SUM(IF(A2:D2="",A1:D1,A2:D2))

Otherwise, confirm the formula in A4 using ctrl+shift+enter.
 
Upvote 1

Forum statistics

Threads
1,215,753
Messages
6,126,677
Members
449,327
Latest member
John4520

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