HTML code is not working in table view
Hi Folks,
I am pretty new in DOMO and need your help.
I tried with the following code in DOMO beast mode.
CASE WHEN DATEDIFF(CURRENT_DATE(), `Last updated Date`) > 3 then concat('<div style="color:red">',`Last updated Date`, '</div>')
ELSE concat('<div style="color:green">', `Last updated Date`, '</div>')
END
but, it doesn't display anything on the table. I tried with save and close and checked in the browser but nothing.
Best Answer
-
odd. I just did a test and it worked.
My beast mode looks like this which is just a copy and paste of what you shared but changed the date field to match the covid dataset field.
CASE WHEN DATEDIFF(CURRENT_DATE(), `date`) > 3 then concat('<div style="color:red">',`date`, '</div>') ELSE concat('<div style="color:green">', `date`, '</div>') END
Do you have any other properties set? Something in the chart properties could be overriding it.
**Make sure toany users posts that helped you.
**Please mark as accepted the ones who solved your issue.1
Answers
-
The basic table card supports a limited amount of HTML in it. To do what you want to do, you need to choose the HTML table card type. This is found under Tables and Textboxes in the chart types dropdown list.
**Make sure toany users posts that helped you.
**Please mark as accepted the ones who solved your issue.1 -
Thanks MarkSnodgrass for the prompt response.
I already tried with HTML table too, but again no result.
Thanks
0 -
I don't see any property set on the chart, but I did apply reset on all properties and magically it's working now.
Thank you, sir.
1 -
@ankt84 that is great to hear it is working! I have had to do the reset chart properties from time to time when something isn't working as expected. If you can mark my answers as accepted, that will help others in the community.
**Make sure toany users posts that helped you.
**Please mark as accepted the ones who solved your issue.0
Categories
- 10.8K All Categories
- 3 Private Company Board
- 1 APAC User Group
- 12 Welcome
- 38 Domo News
- 9.7K Using Domo
- 1.9K Dataflows
- 2.5K Card Building
- 2.2K Ideas Exchange
- 1.2K Connectors
- 343 Workbench
- 258 Domo Best Practices
- 11 Domo Certification
- 464 Domo Developer
- 50 Domo Everywhere
- 105 Apps
- 714 New to Domo
- 85 Dojo
- Domopalooza
- 1.1K 日本支部
- 4 道場-日本支部へようこそ
- 26 お知らせ
- 64 Kowaza
- 299 仲間に相談
- 653 ひらめき共有