How to localize files in Windows Phone 8

*爱你&永不变心* 提交于 2019-12-11 05:39:20

问题


We add key/value pairs in AppResources for each language then easily use it in binding. But I have a long list of names of countries in a separate XML file for each language written in its own script.

Now, how can I use for french the french XML file and for english the english one?

(Answer to the coming question: "what have you tried or where is your code?", infact I'm at the beginning so no code, but I searched but didn't find any result, personally, sorry!)


回答1:


First, why not just convert that XML file to a rex file and then use the standard localization APIs?

Failing that, you could add a localizable string to your application that is the file path to the XML file. That way, you use the standard ResourceManager to get the path and then handle it using your custom parsing.



来源:https://stackoverflow.com/questions/17288568/how-to-localize-files-in-windows-phone-8

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!