Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

If "0" then leave the cell blank

Tags:

I am trying to create a simple ledger and on the far right of the "Book" it totals any debit/credit that I input. But instead of leaving the unused rows blank, it keeps repeating the latest total to the bottom of the page.

How Can I make that cell blank if the equation equals 0?

=H15+G16-F16 

is the formula I am currently using.

like image 400
CJS Avatar asked Aug 23 '15 18:08

CJS


People also ask

How do you leave a cell blank in a formula?

Keep cell blank until data entered in Select first cell that you want to place the calculated result, type this formula =IF(OR(ISBLANK(A2),ISBLANK(B2)), "", A2-B2), and drag fill handle down to apply this formula to the cells you need.

How do I find and replace blank with 0?

Use Excel's Find/Replace Function to Replace Zeros Choose Find/Replace (CTRL-H). Use 0 for Find what and leave the Replace with field blank (see below). Check “Match entire cell contents” or Excel will replace every zero, even the ones within values.

How do you hide a cell with a value 0?

Click on Options. In the Excel Options dialog box that opens, click on the 'Advanced' option in the left pane. Scroll down to the section that says 'Display option for this worksheet', and select the worksheet in which you want to hide the zeros. Uncheck the 'Show a zero in cells that have zero value' option.

How do I do an IF THEN formula in Excel?

Use the IF function, one of the logical functions, to return one value if a condition is true and another value if it's false. For example: =IF(A2>B2,"Over Budget","OK") =IF(A2=B2,B4-A4,"")


2 Answers

You can change the number format of the column to this custom format:

0;-0;;@

which will hide all 0 values.

To do this, select the column, right-click > Format Cells > Custom.

like image 69
Jim Simson Avatar answered Sep 26 '22 07:09

Jim Simson


Use =IF(H15+G16-F16=0,"",H15+G16-F16)

like image 41
ChipsLetten Avatar answered Sep 25 '22 07:09

ChipsLetten