The code is as follows: private static ValueEval EvaluateInternal(ValueEval arg, ValueEval iferror, int srcCellRow, int srcCellCol) { arg = WorkbookEvaluator.DereferenceResult(arg, srcCellRow, srcCellCol); if (arg is ErrorEval) { return iferror; } else { return arg; } } NOPI programmers complain that the above code does not handle missing arguments: https://github.com/nissl-lab/npoi/commit/fa5aab30649ac3344dad34216062cf4dac49efeb Their fixed code is as follows: private static ValueEval EvaluateInternal(ValueEval arg, ValueEval iferror, int... if (arg is ErrorEval) { return iferror; //if the 2nd argument is missing, use an empty string as default if (iferror is MissingArgEval) { return new StringEval(string.Empty); } else { return iferror; } }... }
We are not going to just copy NPOI. Please provide real world examples. POI is a volunteer project and it is normally best to provide a patch with a test case yourself.