With the Red Error measure, we use the ERROR function to return an error when the color Red is selected in the Slicer visualization. The ERROR function throws a DAX error exactly as if a DAX function threw an error during calculation.
With the Red IsError measure, we wrap an IF statement checking for the color Red with the ISERROR function. When an error is thrown by our ERROR statement, the ISERROR function returns TRUE. Otherwise, if the color Red is not present, the ISERROR function returns FALSE. We can use the TRUE/FALSE output of the ISERROR function within a second IF statement to return values based on the error condition returned. In this case, if ISERROR returns TRUE, we return the text Error: Red encountered. Otherwise, we return the variable __Color.
With the Red IfError measure, we wrap an IF statement checking for the color Red with the IFERROR function. The entire code block of our IF statement is the first parameter of our IFERROR function. The second parameter of our IFERROR function is what to return if an error is encountered. In our case, if an error is encountered we return Error: Red encountered. When an error is thrown by our ERROR statement, the IFERROR function returns the second parameter. If no error is thrown, IFERROR simply returns the result of the calculation within the IFERROR function's first parameter (our IF code block).
It should be obvious from this simple example that the IFERROR function is more syntactically efficient than using ISERROR coupled with an IF statement. In fact, IFERROR is more efficient in terms of its overall calculation speed as well. What's more, the IFERROR function operates like a more traditional programming language's try/catch block. In other words, entire complex sections of code can be wrapped with an IFERROR statement where multiple, different errors might occur. Thus, IFERROR is the preferred method of performing error checking in DAX.