Updating data for formula's leading to Uncaught TypeError

The image above shows the table I am currently using where the yellow columns contain formula's. Updating the values in the white columns should therefore update the yellow column values. This works, up to a certain point. When I try to update some of the white cells I get the error:
Uncaught TypeError: Cannot read property '0' of undefined jexcel.js:1558 at updateFormulaChain (jexcel.js:1558) at Object.obj.setValue (jexcel.js:1569) at Object.obj.closeEditor (jexcel.js:1446) at HTMLInputElement.editor.onblur (jexcel.js:1379) at HTMLDocument.jexcel.keyDownControls (jexcel.js:5736)
I wasn't able to figure out what was causing the error, I was hoping you could tell me whether it is something wrong on my end (although I think I did everything according to your documentation) or whether it is something that has to be fixed in the source code?
EDIT: The '0' changes depending on the cell I try to update. So e.g. sometimes it gives the error Uncaught TypeError: Cannot read property '5' of undefined
Can you create a jsfiddle with your table, please?
https://jsfiddle.net/NinjaChristopher/ywjbn5s3/18/
It was due the readOnly directive. I have changed one thing and this will work fine. It will be in the master repository in 30 minutes.
@paulhodel Really appreciate you looking into it!
Unfortunately I am still encountering the issue, as you will be able to see in the JS fiddle. Is it already in the master repository? If so, maybe there is something else going on as well.
@paulhodel Could you please reopen this issue and take another look at what may be causing this. I saw you made some changes, but unfortunately those did not resolve the problem as you can see in the JSFiddle. The same error appears.
// Update formula chain
var updateFormulaChain = function(x, y) {
var cellId = jexcel.getColumnNameFromId([x, y]);
if (obj.formula[cellId] && obj.formula[cellId].length > 0) {
for (var i = 0; i < obj.formula[cellId].length; i++) {
var cell = jexcel.getIdFromColumnName(obj.formula[cellId][i], true);
// Update cell
var value = ''+obj.options.data[cell[1]][cell[0]]; <-- Uncaught TypeError: Cannot read property '0' of undefined
if (value.substr(0,1) == '=') {
records.push(obj.updateCell(cell[0], cell[1], value, true));
} else {
// No longer a formula, remove from the chain
Object.keys(obj.formula)[i] = null;
}
updateFormulaChain(cell[0], cell[1]);
}
}
}
updateFormulaChain(x, y);

Not sure whether this helps, but this is the line where I keep getting the uncaught type error.
Really appreciate all the time and effort you're putting into this!
EDIT: Added screenshot
It has been fixed now.
Not sure whether this helps, but this is the line where I keep getting the uncaught type error.
i am getting the same error
i got the cause of issue this is what i have done to fix the issue locally if by chance anyone wants to refer
var cell = jexcel.getIdFromColumnName(obj.formula[cellId][i], true);
if(obj.options.data[cell[1]]){ // added if condition to check obj.options.data[cell[1]]
// Update cell
var value = ''+obj.options.data[cell[1]][cell[0]];
if (value.substr(0,1) == '=') {
records.push(obj.updateCell(cell[0], cell[1], value, true));
} else {
// No longer a formula, remove from the chain
Object.keys(obj.formula)[i] = null;
}
}
In my case, remaining formula was the problem.
So I cleared formula by sheet0.formual = [] when chnaging sheet data.