Adding Translated Strings to the XML File

The Export XML wizard always exports root strings. Modifications made to the root strings are ignored during an XML import. You can, however, add a translation block to the exported file and add translated strings to it. If it is formatted correctly, the Import XML Wizard will add strings in the new block to the database, and they can be viewed by users whose user profile specifies the locale indicated in the translation block.

To add translated strings to the root strings XML file:

  1. Run the Export Wizard to export root strings to an XML file. For details, refer to Exporting Strings to XML.
  2. Navigate to the export location, and then open the file in your preferred XML editor.
  3. Near the end of the file, you will have an empty <translations/> tag or a <translations> tag followed by a series of <translation> elements. If you have an empty <translations/> tag:
    • Change the empty <translations/> tag into a set of opening and closing <translations></translations> tags.
    • Add a <translation name="locale string"></translation> element.
    <translation name="locale string"></translation>
    Note: The locale string must be the exact ISO 639-1 locale string for the language. Locale strings are made up of a required language part followed by an optional territory. When territory is included, separate language and territory identifiers with an underscore. Examples of ISO 639-1 locale strings include en_US for English (United States) and fr_CA for French (Canada).
  4. Copy all the <string> elements from the root strings portion of the document, capturing all the elements between the <strings> tag and the ending </strings> tag (not including the "strings" tags) and paste this chunk of data between the <translation name="locale string"> and the </translation> tags.
    <?xml version="1.0" encoding="UTF-8"?>
      <string xml:space="preserve" resname="IDS_ABOUT">About</string>
      <translation name="en_US">
       <string xml:space="preserve" resname="IDS_ABOUT">Info</string>
    Tip: Optionally, you may wish to only translate certain strings. If so, copy only the <string> elements you wish to translate to the <translation> tag area.
  5. Translate the copied strings, being careful not to modify the XML tags themselves. Also, keep in mind that you are editing XML. For instance, if you wish to add a "&", you must use "&amp;" or other HTML escape sequences.
    • If you have a <translations> tag with a series of <translation> elements, you may find a <translation> element with the "name" attribute already set to the locale that you wish to edit. If so, you will want to work with that translation element, rather than creating a new one.
    • If you wish to translate more strings than are currently populating your <translation> element, feel free to copy the desired <string> elements from the root area following the directions above. However, do not create duplicate string values in this translation (don't copy string elements from the root area which already have "name" attributes that match the existing string elements in this translation).
  6. Import the XML file using the XML Import wizard. For details, refer to Importing Translated Strings.
  7. Stop and start the SBM Application Engine Web Server.
  8. Instruct users to change the locale in their user profile to that matching the translated strings. The Locale option is located on the Advanced tab of the User Profile page in the SBM User Workspace.