Right now, I have the formula "[Registered Participants][Minimum Participants]". When the value is less than 0, I would like to show the value in red text. Is this possible?
 0 Points
Posted 4 years ago
QuickBaseCoach App Dev./Training (Mark Shnier), Champion
 72,086 Points
You can do this but it's more complicated than just applying a format like you might do in excel. The only way to do this is to create a text string which happens to look like a number and is red if negative. Normally in QuickBase it's not worth the effort, given that the field cannot be used in reports if you need a total as you have the alternative of putting up a formula based warning message or using row colorization on reports.
But you have asked the question and given that your number will be small (way less than 1,000 where you would need to deal with commas) and you have no decimals here is an example of a simple formula. Note that you need to "Enable HTML" by checking the box in field properties. There are more complicated formulas which deal with the more common request which would include larger numbers involving commas, typically Currency with 2 decimals.
If([My Number]<0, "<font color=red>" & ToText([My Number]), ToText([My Number]))
But you have asked the question and given that your number will be small (way less than 1,000 where you would need to deal with commas) and you have no decimals here is an example of a simple formula. Note that you need to "Enable HTML" by checking the box in field properties. There are more complicated formulas which deal with the more common request which would include larger numbers involving commas, typically Currency with 2 decimals.
If([My Number]<0, "<font color=red>" & ToText([My Number]), ToText([My Number]))
 0 Points
Do you know the more complicated formula that involves currency with 2 decimals? That's what I ma looking for.
Thank you!
g
Thank you!
g
QuickBaseCoach App Dev./Training (Mark Shnier), Champion
 72,086 Points
Related Categories

Formulas & functions
 3046 Conversations
 82 Followers

Tables & fields
 7337 Conversations
 200 Followers