I’ve searched extensively and haven’t found any online help about this particular problem, so I hope the Excel gurus here can help.
I have an IF function following the standard structure of IF(Argument, resulttrue,resultfalse) where the false result is “” i.e., display nothing. So far so good. However, I want to append the results of that function with other things using the ampersand (&). The problem is that using ampersand makes the function display 0 instead of a blank, and this appears to override every method of hiding zeros- I’ve found nothing that works.
=IF(C5="",B5*1,"")
i.e., if cell C5 is blank, go ahead and do the calculation on cell B5. If cell C5 is checked, display nothing. Cell C5 is used simply as a binary do/don’t do control.
That works fine. The problem is that adding anything using the ampersand, even something as simple as:
=IF(C5="",B5*1,"")&“text”
will, if C5 is checked, display the result:
That didn’t help but I think I know what’s going on now: I used the Advanced Options to make all zero results blank. However, that applies to the entire cell; if there’s anything else there, everything is displayed; in this case the result of B5*1 when B5 is blank.
OK, back to the spreadsheet, I’ll see if there’s another way, but so far all formatting to hide or eliminate zeros seems to require that that be the only contents of the cell.
Sorry, one last update… experimentation breeds multiple posts, it would seem! I also think I’ve made a mistake in the table in my last post, but it’s such a pain that I’m going to stop trying to make tables!
If you want to avoid the 0 behaviour for B5, you could use something like this:
Yes, I want to not display zeros, so this rather than your following post would be it. I’ll confirm there isn’t anything I’m overlooking but By Jingo, I think that’s it!