Locale error

2 posts, 0 answers
  1. Lewis
    Lewis avatar
    8 posts
    Member since:
    Feb 2015

    Posted 27 Sep Link to this post


    We currently have the following 2 lines of code in our calendar renderer for iOS in the OnElementChanged method in order to arrange the week layout correct in our forms app:

    Control.Calendar = Foundation.NSLocale.CurrentLocale.Calendar;
    Control.Locale = Foundation.NSLocale.CurrentLocale;

    In our application currently on the store this works perfectly. However with the latest version after a series of actions the calendar seems to get into an state where the selected date visually shifts in the ui without publishing the selected date changed event and thereafter all dates get reported at the forms level including the locales time offset (previously utc).

    I can try and put together a sample application if required but it seems to occur if the appointments source gets reassigned - but not every time.

    Is this a known issue?

  2. Lewis
    Lewis avatar
    8 posts
    Member since:
    Feb 2015

    Posted 28 Sep Link to this post

    Problem solved. We had a view with a date picker on it which seemed to affect the locale somehow - even happens with the base XF renderer.

    Changed code in our Calendar renderer as follows:

    Control.Locale = Foundation.NSLocale.FromLocaleIdentifier( Foundation.NSLocale.CurrentLocale.Identifier);
    Control.Calendar = Control.Locale.Calendar;

  3. DevCraft banner
Back to Top