Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

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

Recommended Posts

Posted

Hi,

I'm trying to make the color of a field conditional on the value entered in the field.

If the value in field "test" is Y then i want the color of the field "test" to be green; if the value is N then I want it to be blue.

I have read a number of posts but can't make anything work. I created a global container field gGreen and another one gBlue and formatted one to be green and the other one to be blue. Then I stacked on on top of the other and placed the "test" field on top of both of the container fields. I attempted various ways to put a calculation into the test field but had no success.

Help is much appreciated,

yknot

Posted

yknot,

Try this.

Create one repeating global container field. Lets call is gBackround. For the first global value, enter a blue image, for the second, a green image.

Next create a calculation field that is something like, Case [Test="Yes"; gBackround; gBackround[2] ]

Then put your field with transparent background ontop of the gBackground field. Lay it ontop of it.

Posted

Thanks for the reply - when you say "image" please explain. I tried a repeating field before but when I format the field color I can not format different repetitions with different colors.

Posted (edited)

Hi yknot,

Along with mr_vodka description, take a look at this file I posted to a similar question the other day. I used a mockup dog and Cat graphic, but it pretty much does what he just described.

Click Here

HTH

Lee

I also modified it to follow what you were describing initially.

Lee

yknotTest_.fp5.zip

Edited by Guest
added file
Posted

Thanks Lee,

I got myself tied up in trying to format the container field with different colors.

Are you aware of someplace from where one can import images of color??

yknot

Posted

color is easy, go into layout mode, draw box (usually no lines is best), there is one in the sample I just posted, Fill the Box with the color of choice, Copy the box while in Layout Mode, Then switch to Browse mode, and paste it into the container field of choice.

Lee

Posted

You could also just change the color of the text. See attached Example.

Use the Auto Enter Calculation, note that the "Do Not Replace existing values..." box is not checked.

You can change the colors used in the sample by changing the RGB mix.

HTH

Lee

ChangeTextColor.fp7.zip

Posted

Hi,

I got both the field color and the text color to work thanks to your help. However; when I switch to the "View as Table" mode, the field color method does not work anymore. Field1 separates from c_GraphicField. Any ideas?

yknot

Posted

You can not see graphics like that in Table View (one on top of the other), FileMaker wants to line up your fields in a row, like you would see in Excel.

I would just create a new layout using List View (aka Column View) , and incorporate all of this stuff in it.

Lee

This topic is 6949 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.