Summary
The Excel ISERR function is used to check for the presence of any error value except #N/A in a cell or expression. This function is helpful for error handling within Excel formulas, allowing you to distinguish between different types of errors and take appropriate actions, excluding situations where data is simply not available.
Syntax
=ISERR(value)
- value: The value, cell reference, or expression you want to test for errors
Return value
- TRUE if
valueresults in any error except #N/A. - FALSE if
valueis not an error or if it’s specifically the #N/A error.
How to use
ISERR can be applied directly to a cell reference or an expression. Use it to identify errors in calculations or data inputs, enabling conditional logic or error-specific responses in your Excel sheets.
Examples
Simple ISERR
Checking for an Error in a Cell: Determining if a particular cell, say A1, contains an error other than #N/A.
=ISERR(A1)
If A1 contains any error like #VALUE!, #REF!, or #DIV/0!, this returns TRUE. If A1 is error-free or contains #N/A, it returns FALSE.
ISERR with Formulas
Identifying Errors in Calculations: To detect errors within a complex formula.
=ISERR(1/A1)
This formula checks if dividing 1 by A1 results in an error other than #N/A. It returns TRUE for errors caused by division by zero or invalid cell references.
ISERR with Conditional Logic
Handling Errors Using Conditional Statements: Implementing error checks to provide custom messages or alternate calculations.
=IF(ISERR(VLOOKUP(A1, B2:C10, 2, FALSE)), "Error Detected", VLOOKUP(A1, B2:C10, 2, FALSE))
This formula attempts a VLOOKUP and checks for errors. If an error other than #N/A is detected, it displays “Error Detected”; otherwise, it proceeds with the VLOOKUP result.
Additional Notes
- ISERR is useful for creating more robust and error-resistant Excel models, especially when combined with other logical functions like IF.
- It’s important to remember that ISERR does not catch the #N/A error. For a broader error check that includes #N/A, consider using ISERROR instead.