ERROR.TYPE
Error Information Functions

Basic Description

The Excel Error.Type function receives an error value and returns an integer, that tells you the type of the supplied error.

The syntax of the function is:

ERROR.TYPE( error_val )

Where the supplied error_val is a value or a reference to a cell containing a value, that you want to return the error type of.

The integers returned by the Excel Error.Type function, and their corresponding error types are listed in the table below :

1 - #NULL!
2 - #DIV/0!
3 - #VALUE!
4 - #REF!
5 - #NAME?
6 - #NUM!
7 - #N/A
#N/A - Anything else

See the Excel Formula Error page for more information on each of these error types.

Error.Type Function Examples

The following spreadsheets show four examples of the Error.Type function. The formulas are shown in the spreadsheet on the left and the results are shown in the spreadsheet on the right.

 Formulas:
 AB
1 #VALUE! =ERROR.TYPE( A1 )
2 #REF! =ERROR.TYPE( A2 )
3   =ERROR.TYPE( 1/A3 )
4 10 =ERROR.TYPE( A4 )
 Results:
 AB
1 #VALUE! 3
2 #REF! 4
3   2
4 10 #N/A

Note that the last example, in cell B4, tests the contents of cell A4, which is not an error. Therefore, the Error.Type function returns an error message of its own - the #N/A error.

Excelq.com doing business as a Service of Venttraffic Media Inc. Excel and other words on this site may be trademarks or registered trademarks of Microsoft Corporation. Microsoft Corporation is not connected in any way with this website, and makes no endorsement of the site or its related contents. All rights reserved. Website powered by Venttraffic Media Inc.