Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

changing colour of text based on calc?

Featured Replies

Hi,

Am reasonable new to Filemaker, running 5.5 on Mac OS 9.

I have a contacts database with a list layout and a card index layout. In the card index layout there is a comments field.

In the list layout I have a comments? field, which is a calcultion

comments?=

If(IsEmpty(comments); "no"; "yes")

what I'd really like to do is change the colour of the comments? field, so say if its yes then it'll appear in red bold, so its really easy to scan down the list and see whos got an entry.

Hope thats clear - basically, can you control the font colour / style in a calculation?

thanks in advance

James

  • Newbies

By no means am I one of the established pros here.

Now that I have coverd my back....

It seems to me that you can simply format the text of the "comments?" field as BOLD RED and then change your calc field to say ... If(IsEmpty(comments); ""; "yes")

Then you will have an "empty field" instead of a "no" and you will see BOLD RED text for the "Yes". It should be easy to see with a quick scan of the records.

...Or perhaps, you can use a more complicated alternating global container field (pretty slick) to mark the record with either text of your choosing or perhaps a cool green "check mark" pic for yes and a big red "X" for a no.

The simplest way is to return a blank if it's "no", so that you'll only see something when there is a comment, but if you have to do it the hard way...

The other way is to have two calc fields: one returns a "yes" if appropriate, but is otherwise blank; the other returns a "no"...

Overlay one field on the other in the layout. Make the text colors different for the two fields. Also, make sure that whichever field is in front is transparent (i.e. no fill).

Create an account or sign in to comment

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.