# Globalization

You can have DateEdit in any culture, specially the Japanese culture, a unique feature of our DateEdit control. Read the topic to know more about DateEdit control for WinForms.

## Content



The **Calendar** controls such as **CalendarView** and **DateEdit** allow you to change regional settings to display the calendar UI in specific locales or languages and set right-to-let support.

Let's explore culture settings and right-to-left support in detail using the Calendar controls.

## CalendarView

CalendarView supports built-in globalization to use it in different languages and cultures in the following ways:

*   **Culture settings**: CalendarView supports full localization on week title and month title through the [System.Globalization](https://msdn.microsoft.com/en-us/library/system.globalization(v=vs.110).aspx) Namespace. It includes information pertaining to the culture such as language, country/region, and format patterns for dates, currency, and numbers etc. Specifying locale for the current culture affects the string displayed on the week title and the month title. By default, the current culture designates through the [CurrentCulture](https://msdn.microsoft.com/en-us/library/system.threading.thread.currentculture(v=vs.110).aspx) property of **System.Threading.Thread.CurrentThread**. To use a culture other than the current culture, set the desired culture by specifying the culture name. For more information about different culture names and identifiers, see [CultureInfo](https://msdn.microsoft.com/en-us/library/system.globalization.cultureinfo%28vs.71%29.aspx) class in .NET Framework documentation.
    
    The following image shows CalendarView with the French culture applied.
    
    ![](https://cdn.mescius.io/document-site-files/images/1b33a1f1-17e3-4593-a233-97e8b8ff7610/images/calendarview-cultersettings.png)
    
    The following code snippet shows how to set the current culture in CalendarView.
    
    ```csharp
    // Set desired culture, for example here the French (France) locale.
    calendarView.CurrentCulture = new System.Globalization.CultureInfo("fr-FR");
    ```
    
*   **Right-to-left support**: CalendarView supports Right-to-Left functionality for languages that follow Right-to-Left scripts. The control enables you to display calendar in the Right-to-Left direction by using the [RightToLeftLayout](/componentone/docs/win/online-calendar/) and the **RightToLeft** properties. When both RightToLeftLayout and RightToLeft properties are **true** and **Yes** respectively, the calendar appears in the Right-to-Left direction.
    
    The following GIF displays CalendarView in the Right-to-Left layout.
    
    ![](https://cdn.mescius.io/document-site-files/images/1b33a1f1-17e3-4593-a233-97e8b8ff7610/images/righttoleft-calendarview.gif)
    
    The following code snippet shows how to set the RightToLeftLayout and the RightToLeft properties in CalendarView.
    
    ```csharp
    // Enable the Right to Left Layout
    calendarView.RightToLeftLayout = true;
    // set the RightToLeft property
    calendarView.RightToLeft = RightToLeft.Yes;
    ```
    

## DateEdit

DateEdit supports built-in globalization to use it in different languages and cultures in the following ways:

*   **Culture settings**: DateEdit enables formatting, parsing, and validating data on the basis of a specific culture. The control allows specifying culture(s) through [CultureInfo](https://msdn.microsoft.com/en-us/library/system.globalization.cultureinfo(v=vs.110).aspx) class of the [System.Globalization](https://learn.microsoft.com/en-us/dotnet/api/system.globalization?view=net-7.0) namespace. By default, C1DateEdit uses system CurrentCulture. Setting CultureInfo to Default via designer is an invariant culture and it is based on English culture. So, you need to set the **CultureInfo** property of DateEdit for specifying a culture. The CultureInfo property takes integer value, and utilizes [LCID](https://learn.microsoft.com/en-us/dotnet/api/system.globalization.cultureinfo.lcid?view=net-7.0) property of the **CultureInfo** class.<br />For information about different culture names and identifiers, see [CultureInfo](https://msdn.microsoft.com/en-us/library/system.globalization.cultureinfo%28v=vs.110%29.aspx) class in .NET Framework documentation.
*   **Right-to-left support**: DateEdit provides right-to-left support for languages that follow right-to-left scripts. To enable right-to-left functionality in the DateEdit control, set the [RightToLeft](https://docs.microsoft.com/en-us/dotnet/api/system.windows.forms.control.righttoleft?view=net-5.0) property.

The following image shows DateEdit with Arabic culture in right-to-left direction.

![DateEdit with Arabic culture](https://cdn.mescius.io/document-site-files/images/1b33a1f1-17e3-4593-a233-97e8b8ff7610/images/arabic-culture.png)

The following code snippet shows how to set the current culture and enable right-to-left functionality in the DateEdit control.

```csharp
// set the culture
dateEdit.CultureInfo = new System.Globalization.CultureInfo("ar-IQ");
// enable right to left functionality
dateEdit.RightToLeft = RightToLeft.Yes;
dateEdit.Calendar.DayNameLength = 4;
```

You can also set the DateEdit with Japanese culture:

![DateEdit with Japanese culture](https://cdn.mescius.io/document-site-files/images/1b33a1f1-17e3-4593-a233-97e8b8ff7610/images/japanese-dateedit.png)

The following code snippet shows how to set the Japanese culture in the DateEdit control:

```csharp
dateEdit.CultureInfo = new System.Globalization.CultureInfo("ja-JP");
dateEdit.Calendar.CalendarType = C1.Win.Calendar.CalendarType.JapaneseCalendar;
dateEdit.Calendar.CaptionFormat = "gg yyyy年 MM";
```