🍉 Meet Flexmonster Pivot Table & Charts 2.9.Check out all the hot features!
Get Free Trial

how to replace measure cell content with an icon

Ahmed asked on July 9, 2019

how to replace measure cell content with an icon for example using font awesome classes (‘fa fa-check’ or ‘fa fa-calendar’) depending on condition (when value === 1 then display check icon when value ===2 display calendar icon.)
Thank you.

3 answers

Vera Didenko Vera Didenko Flexmonster July 9, 2019

Hello, Ahmed,
Thank you for your question.
Measure cell content can be replaced with an icon via the customizeCell() API call.
Here is a JSFiddle example showing how this can be achieved.
Please let us know if you have further questions.
Best Regards,

Ahmed July 9, 2019

Hello Vera,
Thank you for your answer.
Kindly, advise, can I display icon using css conditional format instead of replacing cell text (without using cell.text)
Thank you.

Tanya Gryshko Tanya Gryshko Flexmonster July 10, 2019

Hello, Ahmed,

Thank you for your quick reply.

We would like to specify that in order to replace the numbers with custom icons it is necessary to use the customizeCell approach (replacing cell text).

Speaking of conditional formatting options, with the help of conditional formatting pop-up in Flexmonster you can set color, background color and font size.

Hope it helps.


Please login or Register to Submit Answer