Add basic support for Error functions when the error is #SPILL! or #CALC!
This commit is contained in:
parent
dae5dfd6b6
commit
21b784f200
|
|
@ -47,7 +47,7 @@ class ErrorValue
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
return in_array($value, ExcelError::$errorCodes);
|
return in_array($value, ExcelError::$errorCodes) || $value === ExcelError::CALC();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
|
|
@ -22,6 +22,7 @@ class ExcelError
|
||||||
'num' => '#NUM!',
|
'num' => '#NUM!',
|
||||||
'na' => '#N/A',
|
'na' => '#N/A',
|
||||||
'gettingdata' => '#GETTING_DATA',
|
'gettingdata' => '#GETTING_DATA',
|
||||||
|
'spill' => '#SPILL!',
|
||||||
];
|
];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -45,6 +46,10 @@ class ExcelError
|
||||||
++$i;
|
++$i;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ($value === self::CALC()) {
|
||||||
|
return 14;
|
||||||
|
}
|
||||||
|
|
||||||
return self::NA();
|
return self::NA();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -53,4 +53,12 @@ return [
|
||||||
7,
|
7,
|
||||||
'#N/A',
|
'#N/A',
|
||||||
],
|
],
|
||||||
|
[
|
||||||
|
9,
|
||||||
|
'#SPILL!',
|
||||||
|
],
|
||||||
|
[
|
||||||
|
14,
|
||||||
|
'#CALC!',
|
||||||
|
],
|
||||||
];
|
];
|
||||||
|
|
|
||||||
|
|
@ -49,6 +49,14 @@ return [
|
||||||
true,
|
true,
|
||||||
'#N/A',
|
'#N/A',
|
||||||
],
|
],
|
||||||
|
[
|
||||||
|
true,
|
||||||
|
'#SPILL!',
|
||||||
|
],
|
||||||
|
[
|
||||||
|
true,
|
||||||
|
'#CALC!',
|
||||||
|
],
|
||||||
[
|
[
|
||||||
false,
|
false,
|
||||||
'TRUE',
|
'TRUE',
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue