I need a date format that displays the months name and year

I need a Date Format that displays the month's name and the year.

Hi Devon,

Did you take a look in Forge?

Here’s an example component that you could start with.

https://www.outsystems.com/forge/component-overview/7721/month-year-picker

I’m sure there are more.

Regards,

Nordin

Hi Devon,


If you need it in English, why don't you just use the build-in FormatDateTime function?

SyntaxEditor Code Snippet

FormatDateTime(CurrDate(), "MMMM yyyy")


Regards,

Lennart

Solution

Hi Devon,


You can always use the Builtin function FormatDateTime (), providing the date and format you want to display. From what you indicated in the question, it must be of this type FormatDateTime (yourdate, "MMMM yyyy"), that is, if you want to show a date in English.
If you want another language, you must have another function that does the mapping/translation of the month of your date, to the desired language.

Hope this helps. If you need help with the mapping function, let me know.
Regards,Arnaldo

Solution

If you just want to show date as month name and year than like Arnaldo and Lennark sai use in build FormatDateTime function. But if you want to show this format in your date picker using calendar widget then you can simply set DateFormat property of calendar widget. Just hover your mouse on this property and you will see all the option available to set your desired format. Below is the image for reference based on the format you need.