Is it possible to create a localized android application independent from the device's language. For example in .net we set CurrentCulture
and CurrentUICulture
to the specified language, is this possible in android? The goal is to create a multilingual android application.
Asked
Active
Viewed 659 times
1

Cœur
- 37,241
- 25
- 195
- 267

Hassan Mokdad
- 5,832
- 18
- 55
- 90
1 Answers
1
Additional Tips:
To get the current Language :
Locale.getDefault().getDisplayLanguage();
To get the current Locale
String locale = context.getResources().getConfiguration().locale.getDisplayName();
or
String locale = java.util.Locale.getDefault().getDisplayName();
Read this article on Localization strategies
-
Thanks, but what I actually want is not to get the locale, I need to change it and only for my application, not the whole device – Hassan Mokdad Oct 20 '11 at 06:48
-
Oh in that case, [refer to this answer.](http://stackoverflow.com/questions/2264874/android-changing-locale-within-the-app-itself/2271141#2271141) – Reno Oct 20 '11 at 06:50
-
Thanks, it worked great, with your permission I will update your answer to set it as accepted answer, Regards – Hassan Mokdad Oct 20 '11 at 07:43