Adding custom font colors for a transposed row in a table
I want to label the positive numbers in green and negatives in red but only for the second row. How can this be achieved?
Current chart settings is as shown below
Best Answer
-
So this would require you to use an HTML table, which would mean restructuring your data because transpose isn't an option. But if you're really set on changing the font color instead of the cell color, you can achieve that by using this beast mode.
CASE
WHEN SUM(value) < 0 THEN CONCAT('<p style="color:red;">',SUM(value),'</p>')
ELSE CONCAT('<p style="color:green;">',SUM(value),'</p>')
ENDDavid Cunningham
** Was this post helpful? Click Agree 😀, Like 👍️, or Awesome ❤️ below **
** Did this solve your problem? Accept it as a solution! ✔️**1
Answers
-
Not exactly the same, but you can add rules to the Colors chart properties to shade the cell red. I don't think that you can do the font color there, though. If you uncheck "Apply format to table row" it will only shade the cell, so you will get the same effect (highlighting the negatives), but via shade rather than font color.
0 -
The easiest way to achieve this is to set the negative numbers to show in red, and then use card color rules to set > 0 to show in green. The red negative number setting will override the green.
However, this approach causes the cell to be filled in, just an FYI.
David Cunningham
** Was this post helpful? Click Agree 😀, Like 👍️, or Awesome ❤️ below **
** Did this solve your problem? Accept it as a solution! ✔️**0 -
I have already tried both the approaches, but would prefer the changes to be displayed only for fonts than for cells
0 -
So this would require you to use an HTML table, which would mean restructuring your data because transpose isn't an option. But if you're really set on changing the font color instead of the cell color, you can achieve that by using this beast mode.
CASE
WHEN SUM(value) < 0 THEN CONCAT('<p style="color:red;">',SUM(value),'</p>')
ELSE CONCAT('<p style="color:green;">',SUM(value),'</p>')
ENDDavid Cunningham
** Was this post helpful? Click Agree 😀, Like 👍️, or Awesome ❤️ below **
** Did this solve your problem? Accept it as a solution! ✔️**1
Categories
- All Categories
- 1.8K Product Ideas
- 1.8K Ideas Exchange
- 1.5K Connect
- 1.2K Connectors
- 300 Workbench
- 6 Cloud Amplifier
- 8 Federated
- 2.9K Transform
- 100 SQL DataFlows
- 616 Datasets
- 2.2K Magic ETL
- 3.9K Visualize
- 2.5K Charting
- 738 Beast Mode
- 57 App Studio
- 40 Variables
- 685 Automate
- 176 Apps
- 452 APIs & Domo Developer
- 47 Workflows
- 10 DomoAI
- 36 Predict
- 15 Jupyter Workspaces
- 21 R & Python Tiles
- 394 Distribute
- 113 Domo Everywhere
- 275 Scheduled Reports
- 6 Software Integrations
- 124 Manage
- 121 Governance & Security
- 8 Domo Community Gallery
- 38 Product Releases
- 10 Domo University
- 5.4K Community Forums
- 40 Getting Started
- 30 Community Member Introductions
- 108 Community Announcements
- 4.8K Archive