Excel Guides

Returning Zero when a Referenced Cell is Blank in Excel

When you reference a cell in Excel, the cell reference can be blank. This means that the cell doesn't contain any data. If the cell is blank, Excel will return a zero (0) value. You can use this feature to your advantage to make sure that cells with no data don't affect your formulas. For example, let's say you have a formula in cell A1 that multiplies the contents of cells B1 and C1. If either B1 or C1 is blank, the formula will return a #VALUE! error. However, if you change the formula to =IF(B1*C1=0,"",B1*C1), it will return a zero (0) value if either B1 or C1 is blank.

You can also use the ISBLANK function to check if a cell is blank. The ISBLANK function takes a single argument - the cell reference - and returns TRUE if the cell is blank and FALSE if it isn't. For example, the formula =ISBLANK(A1) will return TRUE if A1 is blank and FALSE if it isn't.

If you want to return a different value when a cell is blank, you can use the IF function. The IF function takes three arguments - the condition to test, the value to return if the condition is TRUE, and the value to return if the condition is FALSE. For example, the formula =IF(A1="","N/A",A1) will return "N/A" if A1 is blank and the contents of A1 if it isn't.

Move beyond 

Excel

Get started with Causal today.
Build models effortlessly, connect them directly to your data, and share them with interactive dashboards and beautiful visuals.