User Guide

265
Translating Text Strings You’ve Added or Changed
Translating Text Strings You’ve Added or Changed
When you add or change any user interface elements in an installation, you must
translate those changes if you want them to appear in another language. Examples:
error messages; disk prompts; text and controls on dialogs; descriptions or names for
launch conditions, features, or shortcuts; property values, file names, and directory
names.
You have several options for finding out which strings need to be translated and getting
the translated text into the installation:
! If you change multiple strings and need to send them to a translator, export only the
changed strings to a file. Send the file to a translator, then import the translated
strings back into the installation. See Translating Text Strings by Exporting to a File
on page 265.
! If you make just a few small changes and you know the translations, you can edit the
text directly. See Translating Text Directly Without Exporting It on page 267.
! If you are adding an entire new language, you can export all text strings in the
installation, have them translated, and then import the translated strings to the
installation. See Defining and Translating Into Additional Languages on page 260.
The translated text might require more space than the default language. (Example:
Most languages require more space than English.) Therefore, you might need to resize
dialog controls to accommodate text expansion. See Resizing Dialog Controls After
Translation on page 270.
Note
Dialog controls are shared across all languages, which means that a control you add to one
language is added to all other languages as well. Similarly, a control you delete in one
language is deleted in all other languages. However, you can add conditions to show or hide
certain controls in certain languages. For details, see Conditions for Controls on Dialogs on
page 407. Also see UserLanguageID Property in the Windows Installer SDK Help.
Translating Text Strings by Exporting to a File
When you add or change any user interface elements in an installation, you must
translate those changes if you want them to appear in another language. To do so, you
export the new or changed text strings to a file, have them translated, then import the
translated strings back into the installation. See Exporting Selected Text Strings to a File
on page 266 and Importing Selected Text Strings From a File on page 267.
Example:
Suppose an installation is in English and Spanish. You decide to add a new dialog to the
installation wizard. You add the dialog in the default language (in this case, English).
That way, the dialog is added to all languages in the installation (English and Spanish).
However, because the Spanish text for the new dialog does not exist, the new dialog
displays in English, even in the Spanish version of the installation. You must export all
the text on the new dialog to a file, have it translated to Spanish, and then import the
Spanish version of the text back into the installation.
If you are translating the entire installation to a new language, you can export,
translate, and import all text strings in the installation. See Defining and Translating
Into Additional Languages on page 260. If you make just a few small changes and you
know the translations, you can edit the text directly. See Changing Text in Installation
Expert and Setup Editor on page 268.