Show TOC

Procedure documentationProviding Forms in Multiple Languages Locate this document in the navigation structure

 

To provide forms in multiple languages, you create language-dependent resource files.

Follow the procedure below to translate texts in the actual forms, not in the content.

Default Resource File

When you generate a project, the system creates the following default resource file:

<Preferences location>/<project name>/<project name>.xml

This resource file contains the text that you enter in the Caption property of label controls and other controls.

Example Example

For example, the system has generated the following default resource file for the Demo News project:

/etc/xmlforms/SAP_DemoNews/SAP_DemoNews.xml

End of the example.

The system uses the default resource file if no language-dependent resource file is available in the language of the logged on user.

Procedure

  1. Choose   Content Administration   KM Content  from the top-level navigation bar.

  2. In the project folder, create language-specific and/or country-specific resource files.

    Use the default resource file for your project as a template.

    Use the following naming conventions:

    <preferences_location>/<project_name>/<project_name>__<language_key>.xml

    <preferences_location>/<project_name>/<project_name>__<language_key>__<country_code>.xml

    Example Example

    Examples:

    Resource file for Italian:

    /etc/xmlforms/SAP_DemoNews/SAP_DemoNews__it.xml

    Resource files for English (United States) and English (United Kingdom):

    etc/xmlforms/SAP_DemoNews/SAP_DemoNews__en__us.xml

    etc/xmlforms/SAP_DemoNews/SAP_DemoNews__en__gb.xml

    End of the example.
  3. Open the resource files and translate the text within the text tags.

    Example Example

    For example:

    <TEXT AKEY="lbl_1016189257907" LENGTH="0" TYPE="XFLD">Create or Edit a News Item</TEXT>

    In this line, you would only translate the text "Create or Edit a News Item".

    End of the example.
  4. If you make further changes to the forms following this translation process, decide whether you want the system to regenerate the language-dependent resource files.

    To do this, choose   Options   Project   Update Language-Dependent Resource Files  in the XML Forms Builder.

    • Active: The system regenerates existing language-dependent resource files. Texts whose keys were already available in the resource file remain unchanged - your translations are not lost. New texts appear in the original language, and you can translate them later on.

    • Inactive: The system only regenerates the default resource file, and leaves any language-dependent resource files unchanged. If you created new texts, the system does not display them to users logged on in different languages.

      Note Note

      If the translation is not visible in the forms, you should delete some of the caches:

      Choose   System Administration   Monitoring   Knowledge Management   Cache Monitor  .

      Delete the following caches:

      End of the note.
      • ca_pipeline

      • ca_xmlforms_renderlistitems

      • ca_xmlforms_showforms