Can I format the color of the either font or the column fill on a table card?
Best Answer
-
Here's the way it is written:
CASE
WHEN `Security Risk Rating` = 'EXTREME'
THEN '<div style="background-color:#fcbcb7; color:#800000; font-weight:bold; width: 100%; height:100%; margin:-20px; padding:20px">EXTREME</div>'ELSE `Security Risk Rating`
ENDI had help from Domo Support
1
Answers
-
@crocija, there was a previous post in the Dojo that showed an example similar to what you are trying to do. Take a look at the post at this link and see if this helps you in the right direction.
**Say thank you by clicking the 'thumbs up'
**Be sure to select the answer that represents the best solution and mark as "Accept as Solution"0 -
I'm sorry, but no it did now help. I had already seen the post, but the post fails to explain the actual beastmode formula to type in when creating a new field? Does anybody no that? Let's say the column header is "Totals".
How would I write this in the formula box to make the font red?
0 -
I would like the data in one column to dispay in red. Under Attributes, I can only adjust to italic, bold, etc.
0 -
I am not familiar with HTML myself, but there are numerous examples of HTML related inquiries and responses within the Dojo, which can be located by searching "html formatting". In addition to the one previously provided, here is another that appears to provides some examples of code and results images.
Generally speaking, HTML coding beast mode is not directly supported by DOMO (or at least that's the professed answer), though the solution/link posted in this response was provided by a DOMOsapien.
**Say thank you by clicking the 'thumbs up'
**Be sure to select the answer that represents the best solution and mark as "Accept as Solution"1 -
Okay - I do appreciate your help. The formula wasn't exactly correct.
It's actually this: CONCAT('<div style="background-color:#fccf84; width: 100%; height:100%; margin:-20px; padding:20px"><a href="#">', `Outstanding Minor`, '</a></div>')
Not this: CONCAT('<div style="background-color:#fccf84; width: 100%; height:100%; margin:-20px; padding:20px"><a href="#">', 'Yellow Conditional Format', '</a></div>')
However, I can not set this label to Average. So, I am not able to use this.
How might I beable to have the beastmode created to show Sum, Count, Average, Max, etc.
0 -
Combining a conditional test, and an aggregation, could be a simple matter of wrapping a CASE statement in the appropriate aggregation function.
Ex: SUM(CASE WHEN `TEST` = 'TRUE' THEN 1 ELSE 0 END)
That case could be much more involved with multiple tests, or even nest a CASE within a CASE if you have a two-layer (or more) test to perform. This second example of a multi-layer might be how you wind up incorporating the conditional formatting.
Ex: CASE WHEN SUM(CASE WHEN `TEST` = 'TRUE' THEN 1 ELSE 0 END) < 100 THEN CONCAT('HTML1...')
WHEN SUM(CASE WHEN `TEST` = 'TRUE' THEN 1 ELSE 0 END) < 200 THEN CONCAT('HTML2...')
ELSE CONCAT('HTML3...')
END
Replace SUM with other aggregation functions depending on the context of your solution. A quick generic test in my own instance with the following provided expected results...
**Say thank you by clicking the 'thumbs up'
**Be sure to select the answer that represents the best solution and mark as "Accept as Solution"0 -
I do appreciate the reply, but I'm not netecessarily looking to heatmap sums based on total. The best scenario would simply be to show the color in this column with the total. Because I can't select average, the table shows all of the records for the user. I simpy when to show the total of 7 for the user's reports.
How might I right this to show average?
0 -
Here's the way it is written:
CASE
WHEN `Security Risk Rating` = 'EXTREME'
THEN '<div style="background-color:#fcbcb7; color:#800000; font-weight:bold; width: 100%; height:100%; margin:-20px; padding:20px">EXTREME</div>'ELSE `Security Risk Rating`
ENDI had help from Domo Support
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