1
votes

I'm localizing my Xamarin Forms app. I followed Xamarin's guide, and I added a neutral language resource file (with English text) and an Italian one. I haven't implemented the language detection the guide talks about, yet when I launched it on my Android phone (not an emulator) the correct strings were loaded (Italian for Italian, neutral language for any other language).

Can I safely assume that Xamarin "somehow" now manages the system language detection? Is it some debug-only feature? Do I have to write the platform-specific detection anyway?

1

1 Answers

0
votes

According to Xamarin's documentation:

Xamarin.Forms code can take advantage of .NET's resources to load the correct language translations, but we need to query the operating system on each platform to determine which language the user has selected.

From this I would assume that Android is an exception in this case and that for iOS and other platforms you will need to use a dependency service. The link above has more details on how to implement that.