Hide error values and error indicators in cells
Let's say that your spreadsheet formulas have errors that you anticipate and don't need to correct, but you want to improve the display of your results. There are several ways to hide error values and error indicators in cells.
There are many reasons why formulas can return errors. For example, division by 0 is not allowed, and if you enter the formula =1/0, it returns #DIV/0. Error values include #DIV/0!, #N/A, #NAME?, #NULL!, #NUM!, #REF!, and #VALUE!.What do you want to do?
Format text in cells that contain errors so that they don't show
Display a dash, #N/A, or NA in place of an error value
Hide error values in a PivotTable report
Hide error indicators in cells
Format text in cells that contain errors so that they don't show
- Select the range of cells that contain the error value.
- On the
Hometab, in theStylesgroup, click the arrow next toConditional Formatting, and then clickManage Rules.The
Conditional Formatting Rules Managerdialog box is displayed. - Click
New rule.The
New Formatting Ruledialog box is displayed. - Under
Select a Rule Type, clickUse a formula to determine which cells to format. - Under
Edit the Rule Description, in theFormat values where this formula is truelist box, enter the following formula:=ISERROR(reference)
Where reference is a relative reference to the cell that contains the error value.
-
Click
Format, and then click theFonttab. - In the
Colorbox, select white.
Display a dash, #N/A, or NA in place of an error value
To do this task, use the IFERROR and NA functions.
Example
The example may be easier to understand if you copy it to a blank worksheet.
How to copy an example
- Create a blank workbook or worksheet.
- Select the example in the Help topic.
Note Do not select the row or column headers.
Selecting an example from Help
- Press CTRL+C.
- In the worksheet, select cell A1, and press CTRL+V.
- To switch between viewing the results and viewing the formulas that return the results, press CTRL+` (grave accent), or on the
Formulastab, in theFormula Auditinggroup, click theShow Formulasbutton.
|
|
Function details
Hide error values in a PivotTable report
- Click the PivotTable report.
- On the
Optionstab, in thePivotTable Optionsgroup, click the arrow next toOptions, and then clickOptions. - Click the
Layout & Formattab, and then do one or more of the following:Change error display Select the
For error values, showcheck box underFormat. In the box, type the value that you want to display instead of errors. To display errors as blank cells, delete any characters in the box.Change empty cell display Select the
For empty cells, showcheck box. In the box, type the value that you want to display in empty cells. To display blank cells, delete any characters in the box. To display zeros, clear the check box.
Hide error indicators in cells
If a cell contains a formula that breaks one of the rules, a triangle appears in the top-left corner of the cell. You can prevent these indicators from being displayed.
Cell with a formula problem
- Click the
Microsoft Office Button
, click Excel Options, and then click theFormulascategory. - Under
Error Checking, clear theEnable background error checkingcheck box.
![]()