ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   If A1 is zero, A2 is blank (https://www.excelbanter.com/excel-worksheet-functions/133212-if-a1-zero-a2-blank.html)

woitena1

If A1 is zero, A2 is blank
 
I am trying to make an adjacent cell blank if the related cell is zero. I
have tried conditional formatting and IF formatting, but I still can't get it
to work. Can someone tell me how to do this?


KL

If A1 is zero, A2 is blank
 
- if blank means EMPTY then it can't be achieved by formulas as it literally means EMPTY - no constants, no formulas (you'll need
macros for that)
- if blank means STRING OF ZERO LENGTH ("") then you can try the following formula in [A2]: =IF(A1=0,"",MyAlternative)
the string of 0 length looks like blank, but technically is not blank and behaves differently in most situations (not in all
though).

--
KL
[MVP - Microsoft Excel]
RU: http://www.mvps.ru/Program/Default.aspx
ES: http://mvp.support.microsoft.com/?LN=es-es
EN: http://mvp.support.microsoft.com/?LN=en-us
Profile: https://mvp.support.microsoft.com/pr...A-9E6C73C09A36


"woitena1" wrote in message ...
I am trying to make an adjacent cell blank if the related cell is zero. I
have tried conditional formatting and IF formatting, but I still can't get it
to work. Can someone tell me how to do this?



Beege

If A1 is zero, A2 is blank
 
KL wrote:
- if blank means EMPTY then it can't be achieved by formulas as it
literally means EMPTY - no constants, no formulas (you'll need macros
for that)
- if blank means STRING OF ZERO LENGTH ("") then you can try the
following formula in [A2]: =IF(A1=0,"",MyAlternative)
the string of 0 length looks like blank, but technically is not blank
and behaves differently in most situations (not in all though).



Even a vacuum takes up space, no?

Beege

Herbert Seidenberg

If A1 is zero, A2 is blank
 
A similar problem was posted at ...excel.misc
on Mar 1, "How to find...."
http://preview.tinyurl.com/2uj8pk



All times are GMT +1. The time now is 05:03 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com