Simple IFERROR to return a blank Cell and not a 0

Allen_Mead

New Member
Joined
May 31, 2019
Messages
36
Office Version
  1. 365
Platform
  1. Windows
Hi,

I've trawled through the forum to see if I can find an answer on this but most apply to VLOOKUP which is not appropriate in my case.

I have the following table where I want to add up the number of hours spent on each task, but, if there are no hours, I don't want a 0 in the total column

[TABLE="width: 500"]
<tbody>[TR]
[TD]Task[/TD]
[TD]Mon[/TD]
[TD]Tues[/TD]
[TD]Wed[/TD]
[TD]Thurs[/TD]
[TD]Fri[/TD]
[TD]Total[/TD]
[/TR]
[TR]
[TD]Bob[/TD]
[TD]1[/TD]
[TD]1[/TD]
[TD]3[/TD]
[TD][/TD]
[TD][/TD]
[TD]4[/TD]
[/TR]
[TR]
[TD]Fred[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]

I have to following formula in the total column

=IFERROR(SUM(D7:H7),"")

Which works just fine but leaves a 0 which to my mind shouldn't

Some help would be much appreciated!
 

Excel Facts

What is the shortcut key for Format Selection?
Ctrl+1 (the number one) will open the Format dialog for whatever is selected.
Hi & welcome To MrExcel.
How about
=IF(SUM(D7:H7)=0,"",SUM(D7:H7))

Alternatively just hide the 0 values
 
Last edited:
Upvote 0
You're welcome & thanks for the feedback
 
Upvote 0

Forum statistics

Threads
1,224,817
Messages
6,181,149
Members
453,021
Latest member
Justyna P

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