Forum Discussion

T E's avatar
T E
Copper Contributor
Apr 10, 2018
Solved

Help w/ Nested ISERROR Function

I need some help figuring out why this formula is not working.  I am using Office 2013 and it is an xlsx file.  This is a simplified version of the formula that I am trying to use.

 

In A1 I have =1/0 which returns the #DIV/0! error.

 

In B1 I have =IF(OR(A1="", ISERROR(A1)),"", "Test")

I want B1 to be blank if A1 is blank or has an error, otherwise return 'Test', but instead it returns the same #DIV/0! error.

 

Why is this happening and how do I fix this formula?

Thank you!

  • Hi,

     

    For the purpose of alert, the error always takes on the result of the formula if it appears in any part of the formula!

     

    You have to rebuild that formula as follows to catch the error from the beginning:

    =IFERROR(IF(A1="","","Test"),"")

    Regards

2 Replies

  • Haytham Amairah's avatar
    Haytham Amairah
    Silver Contributor

    Hi,

     

    For the purpose of alert, the error always takes on the result of the formula if it appears in any part of the formula!

     

    You have to rebuild that formula as follows to catch the error from the beginning:

    =IFERROR(IF(A1="","","Test"),"")

    Regards

    • T E's avatar
      T E
      Copper Contributor

      Thank you SO much!  It took me a little bit but I was able to apply the structure of the formula you provided to my spreadsheet and it works!

       

      The trick for me was to create the parts of the formula that work properly and paste that into the 'value' portion of the IFERROR function.

       

      Many thanks for your help! :)

Resources