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

First day of the month format in French


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

Recommended Posts

Posted

In French, the first day of the month should be formatted like this "le 1er juin 2012" even if all the other days of the month don't take a suffix and are like this "le 2 juin 2012". FM's date formatting functions don't allow this. However i 'm sure there is a calculation or a custom function that could do the trick, I just can't figure out how to do it. If anyone has any ideas to get me started, I'd love to here them.

Posted

Try this:

let (



[ myDay = Day ( myDate ) ;



myYear = Year (myDate ) ;



myMonthName = MonthName (myDate ) ;



theSuffix = if ( Day ( myDate ) = 1 ; "er " ; " " ) ] ;



"le " & myDay & theSuffix & myMonthName & ", " & myYear



)

Put it in a Custom Function as e.g. FormattedDate ( myDate ).

Note that Month name uses the date settings of your system, so you must extend this

if you wanted to always get the month name in French, regardless of the user's settings.

Posted

For a widely international solution to this problem, check out http://www.fmfunctions.com/functions_display_record.php?functionId=316

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