Let's say the formula A1/B1 you copied down Column C has some pesky zeros in Column B which inevitably causes the dreaded #DIV/0!. To fix this, try copying and pasting the following formula instead:
This formula is saying the following: If A1/B1 causes any type of error, put a 0 there instead of an error message, else, put the result of A1/B1.
You are not limited to replacing the error with a number. You could also put text:
=IFERROR(A1/B1, "You cannot divide by zero!")
You can use IFERROR for any formula. For instance, here is how you would use it for a VLOOKUP:
=IFERROR(VLOOKUP($A$1:$B$8, 5, 2), 0)
Take a few minutes this week and apply the IFERROR to your formulas!
Get your mother something special next Sunday by giving her a clean-looking spreadsheet. You are bound to be hailed as the greatest son/daughter in the family.
Get your mother something special next Sunday by giving her a clean-looking spreadsheet. You are bound to be hailed as the greatest son/daughter in the family.
No comments:
Post a Comment