0

Formula for colour change

Hello there

 

I have a colour field which i would like to either be red or green depending if a membership has run out based upon another field 'membership expiry date' having gone past the date. Would anyone know a formula for this?

 

Thankyou!

2 replies

null
    • John_Halls
    • 3 yrs ago
    • Reported - view

    Hi

     

    Use a formula field instead of a color field and include this code

     

    styled("", if today() > 'membership expiry date' then "red" else "green" end)

     

    Regards John

    • mratc
    • 3 yrs ago
    • Reported - view

    Hi John,

     

    thanks so much for your reply. Worked like a dream!

     

    Andy

Content aside

  • 3 yrs agoLast active
  • 2Replies
  • 260Views