app studio text
I am starting to use App Studio and would like to do something creative with text. I would like to give a description of charts with text. For example, i would like to create some conditions such as ''met budget'' and to have this in green, otherwise if we did not hit budget to say 'miss budget' based on numbers. Is there any way to represent this? Also is there any way to call the month (August) as a variable or otherwise?
Best Answer
-
My favorite way to do this is in the summary number. You can apply HTML formatting tags to summary numbers. Here's an article with some examples:
I sometimes will use a text card with blank text and only a summary number, since I have more control over the formatting of the summary number than the card itself.
For your case, depending on how your data is set up, your summary number could be something like:
CASE
WHEN SUM(`VALUE`) < AVG(`BUDGET`) THEN
CONCAT('<div style =color:#009E73; font-size:18px; font-weight:900; background-color:#beedd7>',
'Met budget', '</div>')
else
CONCAT('<div style =color:#D55e00; font-size:18px; font-weight:900; background-color:#ffdac4>',
'Miss budget', '</div>')
END
I threw in some other formatting tags you might want in addition to text color.
Please 💡/💖/👍/😊 this post if you read it and found it helpful.
Please accept the answer if it solved your problem.
0
Answers
-
My favorite way to do this is in the summary number. You can apply HTML formatting tags to summary numbers. Here's an article with some examples:
I sometimes will use a text card with blank text and only a summary number, since I have more control over the formatting of the summary number than the card itself.
For your case, depending on how your data is set up, your summary number could be something like:
CASE
WHEN SUM(`VALUE`) < AVG(`BUDGET`) THEN
CONCAT('<div style =color:#009E73; font-size:18px; font-weight:900; background-color:#beedd7>',
'Met budget', '</div>')
else
CONCAT('<div style =color:#D55e00; font-size:18px; font-weight:900; background-color:#ffdac4>',
'Miss budget', '</div>')
END
I threw in some other formatting tags you might want in addition to text color.
Please 💡/💖/👍/😊 this post if you read it and found it helpful.
Please accept the answer if it solved your problem.
0 -
thanks this is VERY helpful. here is the problem i am facing now… When i try this it just resolved to a number when my beast mode is a case statement which has text…..
0 -
Sorry, I meant the "summary number" that's part of any analytics card. I don't think you can apply html tags to smart text within a text card (unless someone knows a way to do that?) The other warning is that HTML tags don't show up in previews; you have to save and close a card to see the formatting applied. Finally, I find these generally work best when you aggregate the values (i.e., put them inside a sum or avg or other aggregating function). Unless your dataset is a single row, it will struggle to combine values and text.
Please 💡/💖/👍/😊 this post if you read it and found it helpful.
Please accept the answer if it solved your problem.
0
Categories
- All Categories
- 1.8K Product Ideas
- 1.8K Ideas Exchange
- 1.6K Connect
- 1.2K Connectors
- 300 Workbench
- 6 Cloud Amplifier
- 9 Federated
- 2.9K Transform
- 102 SQL DataFlows
- 626 Datasets
- 2.2K Magic ETL
- 3.9K Visualize
- 2.5K Charting
- 754 Beast Mode
- 61 App Studio
- 41 Variables
- 693 Automate
- 178 Apps
- 456 APIs & Domo Developer
- 49 Workflows
- 10 DomoAI
- 38 Predict
- 16 Jupyter Workspaces
- 22 R & Python Tiles
- 398 Distribute
- 115 Domo Everywhere
- 276 Scheduled Reports
- 7 Software Integrations
- 130 Manage
- 127 Governance & Security
- 8 Domo Community Gallery
- 38 Product Releases
- 11 Domo University
- 5.4K Community Forums
- 40 Getting Started
- 30 Community Member Introductions
- 110 Community Announcements
- 4.8K Archive