Using the Multilingual App Toolkit for Windows Phone 8 AND Windows Phone 7 Apps

I recently added multilingual support to SpeechJammer after learning about the Multilingual App Toolkit. The Toolkit only supports Visual Studio 2012/Windows Phone 8 though, and I wanted to add language support for both WP8 and WP7 versions of my app. I figured out a pretty easy way to do it that I thought would be worth sharing.

Install the Multilingual App Toolkit if you haven’t already In your WP8 solution go to the TOOLS menu, and select ‘Enable Multilingual App Toolkit’ At this point adding new languages to your WP8 solution is easy, just right click on your main project and select ‘Add translation language’. Notice how every translation language you add creates two new files: AppResources.<language>.xlf and AppResources.<language>.resx After you’ve added all the languages you wish to support, switch over to VS2010 for your WP7 solution. We now want to add all the *.resx files for the various languages you added to your WP8 solution. (The *.xlf files aren’t important to us, they are used by the Toolkit itself, but the *.resx contain the actual translation strings) Right click on your WP7 Resources folder, and choose ‘Add an Existing Item’, then navigated to your WP8 projects resources folder, and select all of the *.resx files that you want to include Instead of clicking ‘Add’ click on the little arrow next to it, then choose ‘Add as Link’. This should bring in all those translated *.resx files, but instead of making a copy of those files, you’ll use the same files as WP8 that can be updated using the Multilingual App Toolkit! Last but not least, you need to modify your WP7 project to reflect these supported languages. Close VS2010 and open up your *.csproj file in a text editor, and look for <SupportedCultures>. You should find a semicolon delimited list of language identifiers. Just add the language codes for the languages which you will be supporting and save the file.

And that’s it. I found the Multilingual App Toolkit to be a great tool, and being able to utilize it to support older platforms made it even better for me.

PS. If anyone knows how to edit that SupportedCultures value in Visual Studio please let me know.