Menu
Download Free Trial

Unable to manipulate cell – customizeCell

Hi!
I’m trying to use the event customizeCell to change the format of my cell. In the trial version I was able to manipulate the way I wanted just fine, but now I’m using the developer license and the event do not have the same behavior as before.
The event receives two parameters, data and cell, with the cell parameters I could simply do “cell.text = personalizedFormat(data.value)”, but now is no longer as object (the “console.log(cell)” shows only the content of the cell as a string). I tried to use the method “getCell(data.rowIndex, data.columnIndex)” but it didn’t work. I also read the thread “http://www.flexmonster.com/question/how-to-change-the-background-color-of-cell-dynamically-using-customizecell/” and even replicate the example in there but no success.
The exact version that was provided to us was “Version 2.324 (build 11/09/2017 09:16:03) – Edition: CSV/JSON/SQL Unlimited – Developer’s version“.
Regards
Elizeu Madeira

7 answers

Public
Tanya Gryshko Flexmonster September 22, 2017

Hello, Elizeu,
Thank you for providing us with such a detailed description.
Our documentation describes customizeCell for version 2.4. Please consider migration to this version. You can find the migration guide by the following link: http://www.flexmonster.com/doc/migration-guide-from-2-3-to-2-4/.
In version 2.3, which you are currently using, the first parameter of customizeCell function was not the cell object but a string containing HTML. You can find the working sample with version 2.3 here: http://jsfiddle.net/flexmonster/q1gtwj48/5/.
Please let me know if your issue was resolved.
Regards,
Tanya

Public
Madeira September 22, 2017

Thanks for the help! I was able to change manipulate the cells using your example now!
I tried to update the version to 2.4 (actually I just put back the trial version and continue using my new developer key) but occur an error when trying to change the aggregation by using the “Field” window (only on Firefox though). I will continue using the 2.3 version until this bug be fixed.
Regards,
Elizeu

Public
Dmytro Zvazhii Flexmonster September 25, 2017

Hello Madeira,
It is great to hear that you have solved the issue with customizeCell. Could you please give us some more information about the issue with changing aggregation in Fields? It would very helpful if you send us the steps for reproducing the issue. Also could you please tell us if the issue is reproducible on our website demo – http://www.flexmonster.com/demos/pivot-table-js/ ? 
Waiting for the update from you.
Regards,
Dmytro.

Public
Madeira September 25, 2017

Hi,
In the demo the Error does not occur, only in my localhost environment. The error also does not occur when the aggregation is defined on init (just when is changed after being loaded).
I’m using Firefox 55.0.3 (32-bit) (I tried in 64 bit version too). The Flexmonster PivotTable version is “Version 2.403 (build 11/09/2017 09:44:07) – Edition: CSV/JSON/SQL Unlimited – Pivot Table & Charts Component – Developer’s version“. I tried load the default language and the “Portuguese” translation JSON.
 The error message in the console is “ReferenceError: event is not defined[Learn More]  flexmonster.js:9:1”.
The steps to reproduce the error is just load some data, open the “Fields” window and, on values area, try to change the aggregation for some field.
I hope my answer be help you find the solution.
Regards 
Elizeu

Public
Tanya Gryshko Flexmonster September 27, 2017

Hello, Elizeu,
Thank you for specifying all the details.
We were able to reproduce the issue on our side. It will be fixed within minor release 2.405, ETA Oct 9.
Please let me know if you have further questions.
Regards,
Tanya

Public
Madeira September 27, 2017

Hello,
We will wait the new release then.
We have no more questions for now.
Thank you very much.
Regards,
Elizeu

Public
Tanya Gryshko Flexmonster October 18, 2017

Hello, Elizeu,
I am glad to inform you that the minor release 2.405 is available for download.
The issue with an error when trying to change the aggregation inside Fields List in Firefox was fixed.
You are welcome to update the component.
Regards,
Tanya

Please login or Register to Submit Answer