Returns a specified value if the expression evaluates to an #N/A error, otherwise returns the result of the expression.
Składnia
IFNA(value, value_if_na)Argumenty
valuewymagane
The value or expression to check for an #N/A error.
value_if_nawymagane
The value to return if the expression evaluates to #N/A.
The IFNA function is used to trap and handle the #N/A error specifically. It allows you to replace the standard #N/A error with a more meaningful value or message in your spreadsheet. Unlike the IFERROR function, IFNA only targets #N/A errors and ignores other error types like #VALUE! or #REF!.
=IFNA(VLOOKUP("Apple", A1:B10, 2, FALSE), "Not Found")→Not FoundReturns 'Not Found' if the VLOOKUP function cannot find the value 'Apple' in the specified range.
Select the cell
Click on the cell where you want to display the result of the IFNA function.
Enter the formula
Type =IFNA( followed by the expression and the replacement value, then close the parenthesis.
IFNA only handles #N/A errors, while IFERROR handles all error types including #VALUE!, #REF!, #DIV/0!, etc.