共用方式為


Multilingual App Toolkit for developing Windows Store apps using Visual Studio 2012

Windows 8 was designed to work better in more locales all over the world. Working with developers like you, we can complete these globalized experiences by releasing apps that are relevant in more locations around the world. By translating using machine translation or localizing using a human translator, you can make your Windows Store app available in more languages and reach more markets and larger audiences. While making apps available on a global scale has always been a priority, with Windows 8 this process is easier than ever.

The release of the Multilingual App Toolkit, an extension to Visual Studio 2012 for Windows 8 (including the free Express version), allows you to easily localize your app by yourself, using the Machine Translation Service, or with the help of localizers. This post provides an overview of why localizing your apps is worthwhile, and how to use the Toolkit to make it easy.

Market opportunities

Microsoft is releasing Windows 8 into 109 languages, including 14 new display languages, and has a potential reach of over 4.5 billion people. With the advent of the Windows Store you can potentially sell apps in more than 200 markets, with support for local currencies in over 70 markets. The Multilingual App Toolkit (MAT) provides access into these markets by helping you create versions of your apps in any of the Windows supported languages.

In addition to reaching into new markets, MAT also enables additional sales potential within the existing market by supporting multilingual households. According to the 2010 American Community Survey, conducted by the US Census, nearly 37 million people in the US are speaking Spanish as their primary language at home. This single example of a market-within-a-market scenario presents a tremendous opportunity for you to begin releasing apps in multiple languages.

With all this market potential, you need an easy way to manage language support. MAT provides this solution for Windows Store app development without adding cumbersome processes or requiring language skills.

Using MAT, you can easily add Spanish to your English Windows Store app and gain access to this market, even if you don’t speak Spanish. Many markets have similar multilingual opportunities that you can reach with the features and workflow management provided by MAT; Spanish apps in the US is just one example of how significant multilingual households can be for you. Now there’s unparalleled opportunity for creating and selling your apps in a global marketplace.

MAT Features

The Multilingual App Toolkit integrates with Microsoft Visual Studio Express 2012 for Windows 8 or Visual Studio Professional 2012 to provide Windows Store apps with translation support, translation file management, and localization editing tools.

The toolkit:

Instructions

Design for globalization and localization.

The Multilingual App Toolkit requires your app be designed for globalization and localization. Once your app supports the Windows Store app globalization and localization design model, the toolkit makes adding languages quick and easy. Refer to Quickstart: Translating UI resources for more info about how to globalize Windows Store apps.

Download the Multilingual App Toolkit.

Download and install the toolkit from Multilingual App Toolkit for Visual Studio 2012.

Enable the Multilingual App Toolkit.

The Multilingual App Toolkit must be enabled for your project before you can begin to localize the app.

To enable the Multilingual App Toolkit:

  1. Open the project solution file.
  2. Select the desired project in the Solution Explorer.
  3. On the Tools menu, select Enable Multilingual App Toolkit.

When you see the message "Multilingual App Toolkit was successfully enabled on the selected project,” the Multilingual App Toolkit is ready to use.

Add languages to the project.

To add languages to your project:

  1. Right-click your project.
  2. Select Add translation languages.
  3. In the Translation Languages window, select the languages you want to release and click OK. The Multilingual App Toolkit output window confirms the addition of the selected languages.
  4. Right-click the project and choose Rebuild to populate contents of the .xlf files in the MultilingualResources language folder.

Right click the solution name and click Add translation languages
Figure 1: Adding new languages 

Notes:
  • The languages you selected have been added to the MultilingualResources folder. Language files are empty when initially created. Strings are populated into these files during the next rebuild.
  • Pseudo Language is listed at the top of the Available Languages list by default. Pseudo Language is the best resource to test that your app is ready for a global market. For more info about how Pseudo Language can be used during testing, see the next step: "Test your app using Pseudo Language".
  • The Microsoft Translator service can be used to machine-translate your app when the Microsoft Translator icon appears after the language name.
  • If you want to remove a language later, right-click the language in the MultilingualResources folder and click Delete. After you’ve added to the project, you cannot remove a language by clearing the check box in the Translation Languages window.

Test your app using Pseudo Language.

Pseudo Language is an artificial modification of the software product intended to simulate real language localization. The pseudo language can be used to detect potential localizability issues or bugs early in the project cycle, before the actual localization starts. For more info about localizability testing with Pseudo Language see Localizability Testing.

To generate pseudo-localized translations:

  1. Right-click Pseudo Language (Pseudo).xlf in Solution Explorer.
  2. Select Generate pseudo translations.

Before you test a pseudo-localized app, you must add Pseudo Language to your Windows 8 language preferences.

Right click the pseudo .xlf file and click Generate pseudo translations

Figure 2: Generating pseudo translations

To add Pseudo Language to Windows 8:

  1. Open the Control Panel, and select Clock, Language, and Region > Language.
  2. Click Add a language.
  3. In the search box, type qps-ploc. Be sure to type the full language code; anything less will not return Pseudo Language in the search results.
  4. Select English (pseudo-qps) and click Add.
  5. Ensure that English (qps-ploc) is at the top of your preferred language list.
  6. You can now start testing your pseudo-localized app.

Add English (qps-ploc) to your languages and move to the top of the list
Figure 3: Move Pseudo (qps-ploc) to the top of your preferred languages

Translate your app into selected languages.

The Multilingual App Toolkit is incorporated within the build process of Visual Studio. During each build, updated strings are automatically added to each language .xlf file under the MultilingualResources folder.

After you've tested your app by using Pseudo Language, there are three options to translate your app into other languages for release. Consider these options in terms of the size and scope of your app. For instance, if you have a few strings in your app that aren’t complex, machine translation might be sufficient for your needs. Whether you possess language skills yourself or know someone who does can help determine what other options work best for your app.

To translate the app yourself:

If you have language skills in more than one language, use the Localization Editor to translate strings yourself. This is easy, as long as you speak the language, and provides control in the translation process and quality.

  1. Right-click the .xlf file you want to translate.
  2. Click Open With...
  3. Select Multilingual Editor (default) .
  4. Select the row that contains the string you want to translate.
  5. Type the translation into the Translation column.

Select a row and type the translation.

Figure 4: The Multilingual Editor

To send the .xlf files to a third party for translation:

You can outsource the localization and editing work to localizers by sending your file via e-mail or to a location on your hard drive from within the Multilingual App Toolkit.

  1. Right-click your desired language .xlf file and click Send for translation.
  2. Click File folder location when you want to send your .xlf file to a local folder. -OR-
  3. Click Mail recipient when you want to send your .xlf file by e-mail.
  4. Click the XLIFF Translation file format.

You can send your .xlf file to a file folder location or a mail recipient
Figure 5: Send .xlf files for translation

To import translated .xlf files into your project:

After localizers complete translation work and you receive the translated .xlf file, you can import the translated .xlf file into your project and build the localized app.

  1. Right-click the desired language .xlf file.
  2. Click Import translation.
  3. Click the .XLF or TPX file to import.

Right-click the .xlf file and click Import translation to import a translated .xlf file

Figure 6: Importing translated .xlf files

Note: The import process performs basic validation before importing. Make sure that the culture code of the xlf you are importing matches the existing xlf or your import might fail.

You and your localizer(s) can manage the status of translations in the Multilingual Editor to review uncertain translations later. You can set the status of each string in the Properties tab. Status values are: New, Needs review, Translated, Final, and Signed off. The indicator at the left of each row shows the status. When all rows show green in the Multilingual Editor, your translation work is done.

To machine translate using the Localization Editor:

To use the Microsoft Translator service for translation suggestions, select a string and click the Translate button. The Multilingual Editor inserts the machine-translated strings into the Target field for you. After the translation suggestion is provided, you can fine-tune the string for your translation style.

Select a string and click the Translate button to use the Microsoft Translator service
Figure 7: Using the Microsoft Translator service for translation suggestions

Upload your app to the Windows Store.

Before you start the Windows Store Certification process, we recommend that you exclude the Pseudo Language (Pseudo).xlf file from your project. Pseudo Language is not a selectable language by the Windows Store, and including it provides no value to your customers. For more info about how to upload your globalized apps to the Windows Store, see Packaging your Windows Store apps.

Summary

The Multilingual App Toolkit makes adding and managing translations easy for your all your Windows Store apps. Some benefits include:

  • The ability to quickly expand your customer base and markets with added languages
  • Developers can focus on source language; MAT provides multilingual resource support
  • You can debug localization issues with pseudo translations
  • Microsoft Translator provides translation suggestions for translator editing

For more info about MAT, see the following:

Download MAT

MSDN Documentation: How to Use the Multilingual App Toolkit

Video: Introduction to the Multilingual App Toolkit

Video: Build Multilingual apps using the Multilingual App Toolkit

--Sara Thomas. Senior PM, Windows International

Comments

  • Anonymous
    October 03, 2012
    Hi, Is it possible to use the Multilingual App Toolkit for localisation of projects that are not Windows Store apps? If not, is it planned to make this possible? Thanks, Martin

  • Anonymous
    October 04, 2012
    My business is on the .Net 3.5 i can't install it in windows 8.i can't install vs2008 or vs2010 ?!!!!!!!!!!!!!!!

  • Anonymous
    October 04, 2012
    @Martin - the Multilingual App Toolkit supports development of Windows Store apps. @firelli - MAT requires Visual Studio 2012. Thanks for checking it out! Here are a couple more Channel 9 videos we've released to help you use the Multilingual App Toolkit: Localizing your app: channel9.msdn.com/.../Localize-Multi-Language-apps-using-the-Multilingual-App-Toolkit Testing your app: channel9.msdn.com/.../Test-Multi-language-apps-using-the-Multilingual-App-Toolkit

  • Anonymous
    October 08, 2012
    I'm currently using it and feature wise it's fine. For English and just two other languages my build times have gone from a few seconds to a few minutes. Is there an easy way to dial down the workload?

  • Anonymous
    October 08, 2012
    The comment has been removed

  • Anonymous
    October 09, 2012
    The comment has been removed

  • Anonymous
    October 10, 2012
    There is a bug in the tool - if the project name has a space in it, the project will fail to build. It looks like MakePri isn't putting quotes around filenames.

  • Anonymous
    October 10, 2012
    Hindi and Asian languages are missing, is it hard to you guys?

  • Anonymous
    October 11, 2012
    @ Philip Colmer: I check out the file name space issue.  Thanks for point it out.

  • Anonymous
    October 11, 2012
    @Jangid: Hindi and Asian languages are selectable via the toolkit and Microsoft Translator service.  Where are you seeing that they are not included?

  • Anonymous
    October 13, 2012
    100000000000000000000000000000000000000000000000000000000000000000000gemas en dragon city

  • Anonymous
    October 14, 2012
    Great blog, There is no error occurring during pre-build or post-build action, but I got nothing generated, is there anyone to help, did I miss something to activate except "Enable Multilingual App Toolkit". Thank you.

  • Anonymous
    October 14, 2012
    Hi, Sara Like to get your advise what are the area need to be updated/Changed for "SampleDataSource" information/data which provided in Grid/Split App VB Template for Windows Store, so the App will read from en-USResource.resw instead for Multilingual App.  Thanks

  • Anonymous
    October 15, 2012
    @BBISA.  Be sure to add resources in the language specific directory (resjson / resw files).  If the XLF files doesn't contain any resource, this is likely the issue.  The How to video will help show this information.  The "Build Multilingual apps using the Multilingual App Toolkit" video (channel9.msdn.com/.../Build-Multi-language-apps-using-the-Multilingual-App-Toolkit) will show all the steps needs to go from a default project to one that is localization ready.

  • Anonymous
    October 15, 2012
    @Paschal9090: If you are using the default grid template, there are a couple of steps you will need to perform to use resources instead of hard-coded text.

  1. You will need instantiate the Resource loader object in the SampleDataSource class (or globally if you are going to use it elsewhere)     Private resLoader As ResourceLoader = New ResourceLoader()
  2. Change the hard-coded strings usage to load the resources from the resw file.  This is done by referencing the Resource Loader instance from step 1.            Dim group1 As New SampleDataGroup("Group-1",                    resLoader.GetString("group1Title"),  '<-- Replaced hard-coded string                    "Group Subtitle: 1",            ...
  3. Be sure to populate the en-usResources.Resw file with the matching resource ID     group1Title : "Happy Dogs"     ... This should get you going. MSDN has some good help on this for Globalizing apps.  Here is the link: msdn.microsoft.com/.../Hh965328(v=win.10).aspx
  • Anonymous
    October 15, 2012
    Thanks Cameron for your quick respond and advise with the links given, will try it.

  • Anonymous
    October 15, 2012
    @Cameron Lerum, Thank you for your respond. I have created manually .resw file for some of my issues, but is there a way to create them automatically for all my xaml controls, because there are many of xaml controls that I must put on the .resw file. Regards...

  • Anonymous
    October 18, 2012
    @BBISA: Sorry - I am not aware of any tool that scans a project's XAML files to create ResW entries.

  • Anonymous
    October 18, 2012
    Hello! I just would like to give a huge thumbs up for the great info you have here on this post. I will be coming back to your blog for more soon.

  • Anonymous
    October 21, 2012
    @Cameron Lerum, Thank you Sir.