I have looked into multiple threads around this one. So here is what I am trying to do. I have a field that has some percentage value. What i would like to do denote this value in different colors based on the range. As an example, 90% would be something like
<h3 color="green">90</h3> so color green. and so on for other ranges.
Is this something possible using formula? I know we can use images and icons and use IF statement but that is not what I am looking for.
Any help will be appreciated.
Thank you
Try this =
IMAGE(
"https://chart.googleapis.com/chart?chst=d_text_outline&chld=" +
IF(
Value__c >= 90,
"00FF00", /*Green*/,
IF(
Value__c >= 60,
"FFA500", /*Orange*/,
"FF0000" /*Red*/
)
) +
"|20|l|000000|b|" +
TEXT(Value__c) + "%",
TEXT(Value__c)
)
Demo: https://chart.googleapis.com/chart?chst=d_text_outline&chld=FFA500|20|l|000000|b|90%
Syntaxchst=d_text_outline
chld=<text_fill_color>|<font_size>|<text_alignment>|<outline_color>|<font_weight>|<text_line_1>|...|<text_line_n>
<text_fill_color>
The text fill color. This is a six-digit hexadecimal color; alpha values are not accepted.
<font_size>
A number specifying the font size, in pixels.
<text_alignment>
The alignment for all text, including the header. Choose one of the following values:
- l - ('L')Left-aligned
- h - Center-aligned
- r - Right-aligned
<outline_color>
The text outline color. This is a six-digit hexadecimal color; alpha values are not accepted.
<font_weight>
Normal or bold text. Underscore ' _' for normal text, and 'b' for bold text.
<text_line_1>| ...|<text_line_n>
The text for the note. Use the | character to indicate a newline. When chst=d_fnote_title, the first line of text is formatted as a title.