Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×
The Claris Museum: The Vault of FileMaker Antiquities at Claris Engage 2025! ×

This topic is 5601 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies
Posted

I am looking for a way to change the color of text in a field based on a number value.

I am a diabetic and when my test result is 200 or more I would like the text to turn red. If it is 199 or less then remain black.

I have tried this:

Case ( BreakfastReading ≥ "200" ; TextColor ( BreakfastReading ; RGB ( 255; 0; 0 ) ) )

but nothing changes.

If it can be done easier please let me know.

Any help would be appreciated.

  • Newbies
Posted

bcooney,

Thanks for the conditional fix. Worked like a charm.

As for the "if" statement.... yea.... I didn't know how to do that. I could get it to do the If (field) is -> 200; :?????

Then I did not know how to get the text color to change to red from black.

The conditional thing worked well. I'm happy.

Thanks again......

Posted

It's better to use conditional formatting for this - but to complete the picture:

You didn't say WHERE you put your formula. Had you used it as an auto-entered calculation, replacing the existing value, it would have "worked" - that is, it would have either changed the color to red or erased the field completely.

In order for it to work well, it needs (1) a default result and (2) a numerical comparison instead of a textual one:

Case ( BreakfastReading ≥ 200 ; TextColor ( BreakfastReading ; RGB ( 255; 0; 0 ) ) ; BreakfastReading )

  • Newbies
Posted (edited)

Comment,

I used the field BreakfastReading and made it a calculation field. I then tried the formula "Case...... " there.

The conditional fix was a perfect fit for me.

I also copy/pasted your formula, after taking off the conditional formatting for each field (breakfast, lunch, dinner, bedtime) but it did not work. So I'm sticking with the conditional formatting solution.

Thanks...

Edited by Guest

This topic is 5601 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.