dmurali
dmurali

Reputation: 293

How to change the language settings in C# Metro App during runtime?

I am developing an Win8 Metro App in C# XAML, which has all the items and their description in English language. But how can I change the language in during runtime, say from English to Spanish or Portugese, by selecting it from a list of available langauges?

I can see that MSDN offeres allowable languages to be used in order to localize the strings but not sure how to integrate them into the App.

Should I just add ApplicationLanguages.PrimaryLanguageOverride to my App.xaml.cs? Or how should the code work?

Any suggestions are most welcome.

Thank you in Advance..!

Upvotes: 0

Views: 710

Answers (1)

atomaras
atomaras

Reputation: 2568

Changing the language, while an App is running, is not supported for Store Apps. The user has to change his Windows language preferences, logout and relogin to his account for changes to take effect thus forcing all Apps to shutdown. I would recommend leaving it as is, meaning one language at a time. Why would you need to do that for a published Store App anyways?

That said, here's an explanation and possible solution/workaround http://timheuer.com/blog/archive/2013/03/26/howto-refresh-languages-winrt-xaml-windows-store.aspx

Upvotes: 2

Related Questions