Explanation
IFERROR is used to handle errors that occur in a formula.
Syntax
=IFERROR(value, value_if_error)
Example
Suppose B2 = 100 and C2 = 0:
=B2/C2
Excel will return:
#DIV/0!
Instead, use:
=IFERROR(B2/C2,0)
Result
0
Another Example
=IFERROR(A2/B2,”Calculation Error”)
If an error occurs in the calculation:
Calculation Error
Real-World Uses
- Division
- Lookup formulas
- Reports
- Data analysis
- Error-free dashboards
Practice
Create a sales report where Quantity may sometimes be zero and use IFERROR to handle calculation errors.