Skip to main content
Question

If Else Statement to Input in a Yes/No Field

  • July 19, 2018
  • 0 replies
  • 87 views

Hello!

I am currently working on a field that ask whether or not a project is +140 days over its due date. I have the field "Over +140?" as a Formula - Rich Text. There is another field I am basing it on, "Days Past Due" which gives the actual number of days past due date. 

I'm hoping to make a if/else statement that will check if the field "Days Past Due" is or over 140, then the field "Over +140" should be populated with the response of "Yes". Otherwise it should be "No". 

I need this field in order to have it as a filter for my table that will show me all the projects that are 140 and more days past due.

Thank you!
This topic has been closed for replies.

  • Quickbase Alumni
  • July 20, 2018

If(

[Days Past Due]>=140,

"<div style='color:red'>Yes</div>","<div style='color:green'>No</div>"

)


the comma separating the two html elements is like "else".

If days past due is equal to or greater than 140, then, Yes in red, else, No in green.



  • Author
  • Quickbase Alumni
  • July 20, 2018
Thank you! However, I forgot to mention that this is a [Days Past Due] is a formula duration field, so it gives me an error that the operator ">=" cannot be use with these types of expressions.

Any help?

[Days Past Due]>=Days(140),

  • Author
  • Quickbase Alumni
  • July 20, 2018
Thank you! I'm almost done I swear. 

No that it works and I have put it as a filter, when I go to the filter itself and it only gives me the option of "<div style='color:green'>No</div>" or "<div style='color:red'>Yes</div>" instead of Yes or No. Any tips?

No problem. Just make a brand new field and have the formula calculate to either yes or no without all the fancy formatting.