Localization codes does not work
I am developing an android app, and implementing localization.
Hence am开发者_运维问答 creating strings.xml in seperate folders such as values, values-ja, values-es.
But, eclipse throws errors for my values folder.
values-es-US is not working for spanish US values-fr-CA is not working french Canada
I was referring to http://download1.parallels.com/SiteBuilder/Windows/docs/3.2/en_US/sitebulder-3.2-win-sdk-localization-pack-creation-guide/30801.htm for the localization codes
Other localizations such as values-hk,values-tw,values-uk seems to fine.
Can somebody point me to the right direction? How can i have separate strings for spanish US and Spain, French Canada and france.
Thanks
Please check out following codes given by the Android.
Locale Code Language / Country
Default English / United Kingdom de-rDE
de-rDE = German / Germany
fr-rFR = French / France
fr-rCA = French / Canada
en-rCA = English / Canada
ja-rJP = Japanese / Japan
en-rUS = English / United States
http://java.sun.com/developer/technicalArticles/J2SE/locale/
Reading that document, i realized i can set the locale with new Locale("fr","ca"); and changing the values folder to values-fr-rCA worked
Thanks
精彩评论