How To: Create Multilingual Documents
Output translated values with Translation Workbench, substitute, or toLabel().
Use template attributes and translated Salesforce values when documents need to match user language settings.
Problem
You need templates that display values in different languages based on user settings or picklist translations.
Solution 1: Using Translation Workbench
Setup Required:
Enable Translation Workbench in Setup.
Translate your picklist values.
Ensure users have language preferences set.
In Your Template:
{{!Product2.Color__c translate="true"}}If the user's language is French and Blue is translated to Bleu:
Result: Bleu
Solution 2: Using Substitute in Related Lists
For German Documents:
<!--{{!
<lineitems>
<listname>opportunitylineitems</listname>
<column>PricebookEntry.Product2.name</column>
<column substitute="true,Ja,false,Nein">IsActive__c</column>
<column substitute="1,Januar,2,Februar,3,März,4,April,5,Mai,6,Juni,7,Juli,8,August,9,September,10,Oktober,11,November,12,Dezember">Month_Number__c</column>
</lineitems>
}}-->Solution 3: Using SOQL with toLabel()
For Related Lists:
Tips
Translation Workbench follows the user's language automatically.
substituteis useful when Translation Workbench is not available.toLabel()respects the user's language.format-datemonth and day names always stay in English.
Last updated
Was this helpful?

