I am sending an attachment using VF Page through batch class. I need to send Labels in PDF in different languages based on Account's organization values.

1 Answer 1


You can use Language attribute from <apex:page> tag like below.

<apex:page controller="controllerName" language="ja">

You can refer to this document for more information

You can refer to this post for your reference

  • Hi Samir, if we give language attribute, for all accounts it will send in same language right. Suppose If the batch class is sending emails of 20 accounts, Labels in Pdf should display in different languages based on their Account's org values. How do we check that condition?
    – Frank
    Mar 10, 2020 at 15:41
  • use the variable for language attribute rather than hard coding the language in VF page and set it from apex class depending on you criteria. You can refer the post in the answer for your reference.
    – Samir
    Mar 10, 2020 at 15:44

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .