Localization is not Being Honored

4 posts, 0 answers
  1. Adam Hill
    Adam Hill avatar
    5 posts
    Member since:
    Feb 2010

    Posted 21 Jun Link to this post

    We are setting the localization of our app via:

    CultureInfo.DefaultThreadCurrentCulture = ...               CultureInfo.DefaultThreadCurrentUICulture = ...

     

    But the RadCalendar is not translating the DayNames nor the Title, (see attached) it remains in English. We also use Humanizer to globalize and it does translate the month name and the ordinal identifiers for languages other than English. (see attached)

    Is there another property RadCalendar is looking at that I need to set? Is there a property of RC I can set to force it? (since we do language switching inside our app)

     

    Thanks,

     

     


  2. Didi
    Admin
    Didi avatar
    73 posts

    Posted 25 Jun Link to this post

    Hi Adam,

    Thank you for the provided image. As I see from it the issue is oбserved on the iOS platform. The RadCalendar control doesn't detect the device language if the language is not explicitly added in the application info.plist file (the file is located in the iOS project). In order to achieve this please add the following code in the info.plist file: 
    <key>CFBundleLocalizations</key>
        <array>
            <string>English</string>
            <string>Russian</string>
            <string>Spanish</string>
        </array>

    Please take a look at the provided sample example. 

    Regards,
    Didi
    Progress Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  3. Adam Hill
    Adam Hill avatar
    5 posts
    Member since:
    Feb 2010

    Posted 26 Jun in reply to Didi Link to this post

    Ok. That fixed iOS, thanks!

    But another issue popped up - the calendar seems to only honor the locale when the app is restarted. So if we change the Culture and UICulture manually *in* the app, the Calendar does not pick up on it until we restart the app.

    Is there a way to for the Calendar to pick up a new culture? I did not see an obvious attribute in XF to bind to.

    Thanks.

  4. Didi
    Admin
    Didi avatar
    73 posts

    Posted 28 Jun Link to this post

    Hi Adam,

    I will need more details on how you set the Culture manually in the app. It could be really helpful if you could send us a sample project where the issue is reproduced. Please open a support ticket and attach it there, as in the forum only image attachments are allowed. An alternative is to share the code you use here, however, having an actual sample will be very useful for us.

    Also, please note that by default the Calendar control uses the device culture. If you want to set another culture manually, you need to create a custom renderer and use the following code:

    CalendarView.Locale = new NSLocale ("ru_RU");
    For more details how to achieve this, please refer to the link below: 
    https://docs.telerik.com/devtools/xamarin/nativecontrols/ios/calendar/localization

    Regards,
    Didi
    Progress Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Back to Top