0

I'm working with localization. So the structure ( Base.lproj folders, Localizable.strings ) is already setup and the app is loaded in the correct language (depending on your phone settings). However, in the app, the user needs to be able to change the language via a view. How can I change the language on the fly without restarting the app. here a solution but it seems not very good

    var path = NSBundle.MainBundle.PathForResource("fr", "lproj");
    var languageBundle = NSBundle.FromPath(path);
    var myLocalizedString = languageBundle.LocalizedString("locloc", " ");
Joe Sleiman
  • 2,416
  • 5
  • 25
  • 40
  • https://www.factorialcomplexity.com/blog/2015/01/28/how-to-change-localization-internally-in-your-ios-application.html – SushiHangover Aug 30 '17 at 07:58
  • i don't know how to translate it to xamarin as i'm new to xamarin and c# very beginner.@SushiHangover. also i find a solution but not very good : view my update question – Joe Sleiman Aug 30 '17 at 08:27

0 Answers0