01 Ağustos 2012 Çarşamba 12:05
03 Ağustos 2012 Cuma 09:43Moderatör
To help localize a Metro style app, you can add one or more Resources File item templates (.resjson files) to your project.
For more info, see Globalizing your app, it provide a best practice scenario to globalize and localize your Metro style app.
Hope it helpful.
03 Ağustos 2012 Cuma 09:48
I already have .resjson file and I'm able to successfully bind static text. But what about binding inside a ListView template? Let's say my datasource contains strings like "LABEL_1" and "LABEL_2", and I'd like to bind these identifiers to resource file so that user eventually sees "LABEL_1" and "LABEL_2" in his own language.
Hope I didn't complicate it too much ;) Thanks.
06 Ağustos 2012 Pazartesi 11:09Moderatör
You should have different language Datasource.
If you use a web service, you need to provide each language version.
For example you request data from a web service, request string is:
var userInputLanguage = Windows.Globalization.Language.currentInputMethodLanguageTag;
var requestStr = "http://www.webservice.net/json.aspx?";
If your current input language is US English this requestStr will be http://www.webservice.net/json.aspx?language=en-us
Then do the binding as usual.
If you use Other data source you can also refer to this experience.
- Yanıt Olarak İşaretleyen Docentus 06 Ağustos 2012 Pazartesi 12:22
06 Ağustos 2012 Pazartesi 12:23
Seems reasonable to have a language distinction in the datasource, thanks for the tip :)