When a array is set to mergeCells property, functions are replaced by its values

Tags: #<Tag:0x00007f8b1d285190>

Hello!

I made a sample with the error:

https://jsfiddle.net/63cd1zLe/

Basically, if I have I have a cell with a formula and I set an array to mergeCells property in Handsontable initialization, the formula is replaced by its value (Click on the cell A1 to edit, the number 3 is shown, not =1+2).
It seems that it doesn’t happen if mergeCells property is set as a boolean.

I’m setting it wrong or something? I looked at documentation example of how to set it and it seems to be right, but let me know

If this is actually a handsontable problem, is there any forecast about when an update with a fix about will be release? Is there any workaround?

I’ve open a question about it before, but I couldn’t find the reason, anyway here’s the link:

Handsontable version: 9.0.1

Hi @nathalia.pissuti

This issue (described by https://github.com/handsontable/handsontable/issues/6359) is a part of the scope of the II stage of the formula integration. It hasn’t been scheduled yet.But I will make sure to notify you once we fix it,

1 Like

Thank you for answer me!
Is there a workaround?

A workaround would be to reapply the formulas after Handsontable is initialized https://jsfiddle.net/ja15bckq/

1 Like

Just a comment to other developers, populateFromArray is called in a lot of other moments (Ex: paste value, add row, add col, etc), so it is necessary to keep a track of your formulas

Yes, it is also important to mention that the following change has its own source-string that can be used to identify if from the other changes within beforeChange/afterChange operations ref: https://handsontable.com/docs/api/core/#populatefromarray

Hey @nathalia.pissuti

I’m more than happy to announce that this issue is fixed in the latest version - 12.2.0.
Here https://handsontable.com/docs/react-data-grid/release-notes/#_12-2 you can read more about the changes in this version.