Using Case to change color of a field on a form

  • 0
  • 1
  • Question
  • Updated 2 years ago
  • Answered
Im using a formula text button to change background color of fields based on the text like below, but I want that anything NOT in the list has a normal background. 

What is happening is that the additional entries are blank.

Case([Fund Entry], "FIRST", "<div style=\"color:white;background-color:red;\"> FIRST</div>",

"SECOND","<div style=\"color:white;background-color:blue;\"> SECOND</div>",

"THIRD","<div style=\"color:orange;background-color:black;\"> THIRD</div>","")

If there is a FOURTH, how can I get it to just show normally (until I decide to color it later) ??
Photo of Michael Graham | Insight Global UK

Posted 2 years ago

  • 0
  • 1
Fixed it -

"THIRD","<div style=\"color:orange;background-color:black;\"> THIRD</div>",[Fund Entry])

I was using & round the &[Fund Entry]&   which isn't necessary.
Photo of Matthew Neil

Matthew Neil

  • 31,698 Points 20k badge 2x thumb
Marking as answered to remove from list.  Good work.