Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
245
DateTimeEditor and MonthCalendar localization
posted

Many Infragistics controls allow to localize them and change strings in the runtime. Appropriate string are defined and described in documentation. But I haven't found them for XamDateTimeEditor and XamMonthCalendar controls. The only way I've found is by setting up Language XmlMarkupp property. I could bind this property from the ViewModel but why should I, when there is no need to do this for other controls (data grid, dock manager, etc). This is not much convenient and definitively not consistent with other controls. Or am I missing something?

  • 54937
    Offline posted

    The strings of other controls such as dialog messages, captions, etc are custom strings specific to those controls. In the case of the xamMonthCalendar, the strings you are talking about are general calendar related strings - e.g. month and day names. The .net framework provides support for getting localized month/day names, all the date formats,etc. (see DateTimeFormatInfo). We wouldn't want to override or duplicate that so the templates of the various elements in the xamMonthCalendar are using WPF bindings and the culture of those bindings when converting a DateTime to a string. The CultureInfo provided to a WPF binding is based upon the Language property.