Translating Custom Labels

Most of the text you see in Altify software is governed by custom labels. For example, the contact details fields you see on relationship maps have custom labels.

The sections that follow explain how you can use STF files to export custom labels, get them translated into a particular language, and import them back into the org.

Tip: If you just want to translate a few specific labels, you can do so in Salesforce without recourse to STF files. For more information, see the Salesforce online help.

Overview

Custom labels are imported and exported in an STF (Salesforce Translation Format) file. An STF file includes:

  • A header area specifying the language code. This code applies to all the labels included in the file.
  • A list of labels. There is one label per line. A tab separates the "key" (label ID) and the label itself. (The tab is mandatory. Using spaces to separate them will lead to an import error.)

In outline, the basic steps are:

  1. Ask Altify for the master STF file containing all Altify custom labels.
  2. (This file includes a comprehensive set of comments explaining how to use the file, and which labels apply to which area of the software.)

  3. Delete any sections that are not relevant to you. For example, if you're not licensed for Account Manager, delete the section containing Account Manager labels.
  4. Each language requires its own separate STF file, so make a copy of the file for each language you want to support, and specify the language code in the header.
  5. Send the file to the translator so that they can translate the label text.
  6. When you get the translated file back, import it back into Salesforce.

The sections that follow explain the process in more detail.

Making a Suitable Copy of the Altify STF File

Suppose that you want to translate Altify into German. First, you need to make a suitable copy of the master STF file.

  1. Ask Altify to give you a copy of the master STF file.
  2. Open the file with the text editor of your choice, such as Notepad++ or Sublime.
  3. Note: Do not open the file in Microsoft Excel. This may add extraneous characters that corrupt the file.

  4. The master STF file includes all Altify custom labels. However, you only need to translate labels for the modules you're licensed for.
  5. The file is organized into sections to make it easy to see which labels are associated with each module. Delete any sections not relevant to your users.

    For example, if none of your users are licensed for Account Manager, delete the Account Manager sections of the master STF file.

  6. If the file does not already specify the correct language code, change it in the header area.
  7. For a full list of supported languages and their codes see this Salesforce help page.

  8. Save the file to a suitable location. Use a name that indicates the file is for Brazilian Portuguese translation.

Sending the File to Your Translator

Send the STF file to your Brazilian Portuguese translator.

They should translate the label (indicated in green below). They should not translate the keys or the text in the header area.

Labels have a 1000 character limit (including white space), so it is important that the translated text does not exceed this.

Tabs (\t), new lines (\n) and carriage returns (\r) are represented by special characters in label text. These characters should be preserved in the translation so that formatting is maintained.

Certain labels includes parameters that are substituted in the software. These have the syntax ${value} or {value}. They should be left unchanged in the translated text.

Note: The translator should make sure that the translated text is synonymous with the default English text. Otherwise, it may not match the software logic.

Import the Translated File into Salesforce

When you receive the translated STF file back from the translator, import it into your org using the Translation Workbench.

To import an STF file:

  1. In Setup, go to Translation Workbench > Import.
  2. On the Import screen, click the Choose File button.
  3. Select your edited STF file and click Import.
  4. You should receive an automatic email confirming that your translation was implemented successfully.

(It may take a few minutes before the translations are visible in your org.)

The translated text is now visible to any user set to this language in Salesforce.

If the import fails, review the messages in the log file added to the Documents tab. This will help you to resolve the issue(s) that caused the failure.

Points to Note

  • In addition to Altify custom labels, certain Salesforce standard labels are also presented on Altify pages. These relate to Opportunity Stage, Contact Role, Task Priority, Task Status, and Salutation. These standard labels also need to be translated. They are:
  • PicklistValue.Standard.opportunityStage.Closed Lost

    PicklistValue.Standard.opportunityStage.Closed Won

    PicklistValue.Standard.opportunityStage.Id. Decision Makers

    PicklistValue.Standard.opportunityStage.Needs Analysis

    PicklistValue.Standard.opportunityStage.Negotiation/Review

    PicklistValue.Standard.opportunityStage.Perception Analysis

    PicklistValue.Standard.opportunityStage.Proposal/Price Quote

    PicklistValue.Standard.opportunityStage.Prospecting

    PicklistValue.Standard.opportunityStage.Qualification

    PicklistValue.Standard.opportunityStage.Value Proposition

    PicklistValue.Standard.taskPriority.High

    PicklistValue.Standard.taskPriority.Low

    PicklistValue.Standard.taskPriority.Medium

    PicklistValue.Standard.taskStatus.Completed

    PicklistValue.Standard.taskStatus.Deferred

    PicklistValue.Standard.taskStatus.In Progress

    PicklistValue.Standard.taskStatus.Not Started

    PicklistValue.Standard.taskStatus.Waiting on someone else

    PicklistValue.Standard.salutation.Dr.

    PicklistValue.Standard.salutation.Mr.

    PicklistValue.Standard.salutation.Mrs.

    PicklistValue.Standard.salutation.Ms.

    PicklistValue.Standard.salutation.Prof.

  • The following are picklist value sets created by the Altify package on install. Your administrator configures these values to include your organization's picklist values.

    • Altify Insight Tags

    • Altify Personas

    The picklist values are candidates for translation via the stf file.

  • If the Output Extension App is installed in your org, it's mandatory to translate the following custom label:

  • CustomLabel.DMPPT__Click_To_Save

    However, if the app is not installed in your org, the import will fail if this label is included in the STF file.