Beispiel #1
0
        void SetCalendar(string cultureCode, System.Globalization.Calendar calendar)
        {
            var culture = new System.Globalization.CultureInfo(cultureCode);

            if (System.Array.IndexOf(culture.OptionalCalendars, calendar) == -1)
            {
                Debug.Log("Calendar " + calendar.GetType().Name + " not supported by culture " + cultureCode);
                return;
            }

            culture.DateTimeFormat.Calendar = calendar;
            Calendar.Culture = culture;

            Calendar.UpdateCalendar();
        }