ERROR.TYPE Function
Return the number of an error value: 1 for #NULL!, 2 for #DIV/0!, 3 for #VALUE!, 4 for #REF!, 5 for #NAME?, 6 for #NUM!, 7 for #N/A, 9 for #SPILL! and 10 for #CALC!. A value that is not an error returns #N/A, so combine ERROR.TYPE with ISERROR or IFERROR to test any value.
Syntax
ERROR.TYPE(value)
Category: Information. Minimum arguments: 1. Maximum arguments: 1.
Available for supported offline calculation.
Examples
=ERROR.TYPE(1/0)
The formula returns 2, the number of the #DIV/0! error of 1/0.
Cell and range examples require appropriate input values in the referenced cells. Handle invalid arguments, formula errors and array and spill constraints.