MindFusion.Charting for JavaScript Programmer's Guide
DateFormats.yearMonth Property
See Also
 






Gets or sets the year-month format string.

Namespace: MindFusion.Common
File: Locale.js

 Syntax

JavaScript  Copy Code

get yearMonth() {}
set yearMonth(value) {}

 Property Value

Type: String
String

The long year-month format string.

 Example

The following code creates a new Locale instance that uses the DateFormats property to initialize the desired date and time formats.

JavaScript  Copy Code

var locale = new Locale("us-2");

locale.dateSettings.dateFormats.shortDate = "MM/d/yyyy";
locale.dateSettings.dateFormats.shortTime = "h:mm tt";
locale.dateSettings.dateFormats.shortDateTime = "MM/d/yyyy h:mm tt";
locale.dateSettings.dateFormats.longDate = "dddd, MMMM dd, yyyy";
locale.dateSettings.dateFormats.longTime = "h:mm:ss tt";
locale.dateSettings.dateFormats.longDateTime = "dddd, MMMM dd, yyyy h:mm:ss tt";
locale.dateSettings.dateFormats.dayMonth = "d/MM";
locale.dateSettings.dateFormats.yearMonth = "MMMM, yyyy";

locale.dateSettings.generate();

calendar.locale = locale;

 See Also

DateFormats Members
DateFormats Class
MindFusion.Common Namespace