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.

Conditionally format Day Name

Featured Replies

Hello again

have a date field that is an auto enter creation date.

I need to format just the day name to a different color.

[color:red]Mondays

[color:green]Tuesday

etc

The field is formatted as Monday, 1 January 2007

I can't seem to get it to work

Help!!!!

If this is for version 8.5, you will need to use a calculation field with a Text result for this.

  • Author

Thanks for the response

I kinda figured that but can't quite figure out how to do the calc.

Should the date field be a text field or a calc field. And if it is set to auto enter, how do i turn it into a text field?

Remember, I am still new to all this.

Have tried to set it as a calc field results as text and cannot change it to display the way i wanted in the above post. Wednesday, 14 November 2007 displays as 14/11/2007.

Edited by Guest

Your date field should remain as a date. Create a new calculation field with Result Is Text as shown below:

Case(

DayOfWeek(MyDateField) = 2; TextColor ( "Monday" ; RGB ( 255 ; 0 ; 0 ) );

DayOfWeek(MyDateField) = 3; TextColor ( "Tuesday" ; RGB ( 0 ; 255 ; 0 ) );

DayOfWeek(MyDateField) = 4; TextColor ( "Wednesday" ; RGB ( 0 ; 0 ; 255 ) )

)

You should probably leave the CreationDate field as it is (if it's not a date, you won't be able to use it for finding or sorting), and add a new field defined as a calculation (result is Text) =

TextColor (

DayName ( CreationDate ) ;

Choose ( Mod ( CreationDate ; 7 ) ;

RGB ( 0 ; 200 ; 0 ) ;

RGB ( 200 ; 0 ; 0 ) ;

RGB ( 0 ; 0 ; 200 ) ;

RGB ( 200 ; 200 ; 0 ) ;

RGB ( 0 ; 200 ; 200 ) ;

RGB ( 200 ; 0 ; 200 ) ;

RGB ( 200 ; 200 ; 200 )

)

) & ", " &

Day ( CreationDate ) & " " &

MonthName ( CreationDate ) & " " &

Year ( CreationDate )

Then use this field for displaying the date.

  • Author

Again Thanks

Comment,

That works Beautifully, I had come to a similar solution the difference was that I got the day name in a text field and applied the formating to it. A little clumsy but it worked. This is a much more elegant solution. It was also good to learn about the chose and mod functions.

Thanks again

Edited by Guest

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.