To Leave Cell blank Please

S

Steved

Hello from Steved

If no Data the cell is returning a 0 value I need it in this case to be
blank please.

SUM(IF('From Charters'!$A$1:$A$900="Roskill",IF('From
Charters'!$B$1:$B$900="Period.1",'From Charters'!$D$1:$D$900,0),0))

Thankyou.
 
B

Biff

Hi!

Sometimes it's more efficient to use conditional formatting to "hide"
unwanted returns!

Instead of using an array SUM(IF, use this:

=IF(SUMPRODUCT(--('From Charters'!$A$1:$A$900="Roskill"),--('From
Charters'!$B$1:$B$900="Period.1"),'From
Charters'!$D$1:$D$900)=0,"",SUMPRODUCT(--('From
Charters'!$A$1:$A$900="Roskill"),--('From
Charters'!$B$1:$B$900="Period.1"),'From Charters'!$D$1:$D$900))

If your wb is large with lots of these types of formulas consider this:

This formula takes twice as long to calculate and uses relatively large
arrays.

Biff
 
S

Steved

Hello Biff from Steved

Thankyou and yes I've taken on board your comment about large Worksheet
but in this case it is a small one

Thankyou.
 
D

Domenic

You can also custom format your cell...

Format > Cells > Number > Custom > Type: 0;-0;;@

Hope this helps!
 
D

Domenic

I like it too, but I have to keep referring to the help file to make
sure I've got it right. :)
 
S

Steved

Hello Domenic from Steved

Domenic thankyou, Thius is a much better solution because you have a much
clearner formula.

Great Stuff

Thanks again for your thoughtfulness.
 
B

Biff

Just be aware that just because you don't see a zero in that cell there is
one!

So, if say, you wanted to then average values in a range that carried that
format, the unseen zeros could cause a problem!

Biff
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top