Feb 26 2020 05:53 AM
Hi, I am trying to hide error string messages in a formula cell when it calls on data from a cell that is blank. The formula needs data from 2 cells and when I fill in 1 of the cells, the error messages are shown until the data is entered into the other cell. Is there a way to hide these strings?
Feb 26 2020 06:28 AM
The simple answer is "Yes"
In fact, there are probably several ways to do it. Can you upload your actual file (or a sample of it) so that I or someone else can give a specific recommendation?
In the absence of that, let me recommend that you research functions like IFERROR or IFNA as potential solutions. You might be able to resolve this totally on your own through one of those.
Feb 26 2020 08:21 AM
@mathetes Thanks, here is a sample piece.
Feb 26 2020 12:30 PM
@JoeRock There is no error! You formula in C5 merely returns a value of -$177,775,00. The column width is simple not large enough the display that number. See below.
Feb 28 2020 12:04 PM
@Riny_van_Eekelen Thank you for that info. I guess the question now would be: Is there a way to hide the info in C4 and C5 unless both C2 and C3 have data entered into them?
Feb 28 2020 12:30 PM
Feb 28 2020 12:37 PM - edited Feb 28 2020 12:52 PM
In C4:
=IF(OR(ISBLANK(C2),ISBLANK(C3)),"",(C3-C2)/0.25)
in C5:
=IF(OR(ISBLANK(C2),ISBLANK(C3)),"",C4*12.5)
.... or see attached. Although, I note that C3 is not part of any of your formulae, so C3 being blank or not has no impact..
Edit: Corrected the first formula!
Feb 28 2020 12:41 PM - edited Feb 28 2020 12:52 PM
@Riny_van_Eekelen Must have accidentally overwritten part of the formula in C4. Hence, my comment that C3 is not part of any formula.
Feb 29 2020 11:50 AM
@Riny_van_Eekelen Thank you so much for all your help. It worked, but I wanted the original values of 0 for C4 & $0.00 for C5 to be present even when C2 & C3 were blank. I figured out by putting the values in the quotes that it does the job. So this is what they look like now.
C4: =IF(OR(ISBLANK(C2),ISBLANK(C3)),"0",(C3-C2)/0.25)
C5: =IF(OR(ISBLANK(C2),ISBLANK(C3)),"$0.00",C4*12.5)
It seems to work. If you see anything wrong with it please let me know.
Again thanks so much for your help!!
Feb 29 2020 01:32 PM
@JoeRock That would work fine. Though, putting the 0 or the $0,00 between quotes ("") makes them texts. You can skip the quotes if you want to return the number -zero- (formatted as $, if you want) as values.
Feb 29 2020 01:54 PM
@Riny_van_Eekelen so then it would look like this?
C4: =IF(OR(ISBLANK(C2),ISBLANK(C3)),,(C3-C2)/0.25)
C5: =IF(OR(ISBLANK(C2),ISBLANK(C3)),,C4*12.5)
This way the cell retains it's number format. Is that correct.
Thanks JoeRock
Feb 29 2020 09:50 PM
@JoeRock I meant this:
C4: =IF(OR(ISBLANK(C2),ISBLANK(C3)),0,(C3-C2)/0.25)
C5: =IF(OR(ISBLANK(C2),ISBLANK(C3)),0,C4*12.5)
and then display C5, using the Currency format, as dollar.