Forum Discussion

jcapezzuto's avatar
jcapezzuto
Resolver I
7 years ago
Solved

Setting language and locale for embedded report

We are using the Javascript API to embed reports in our web app.  We need to control the report language and locale settings for our users based on settings in our app.  In the example below, we are trying to set the language to Portuguese "pt" and the locale to Portuguese-Brasil "pt-BR".  We are defining the localeSettings (as described here https://github.com/Microsoft/PowerBI-JavaScript/wiki/Embed-Configuration-Details) and can see our settings returned in the embed object (see below) but the settings are not being picked up by the report.

 

 

Can anyone offer a suggestion here?

 

 

 

  • We were able to make this work by directly adding &language and &formatlocale parameters to the embed URL.  

9 Replies

  • We were able to make this work by directly adding &language and &formatlocale parameters to the embed URL.  

    • Anonymous's avatar
      Anonymous
      Not applicable

      Hi.
      Just curious because I have kind of the same challenge as you did.


      I would like to create some PBI-embedded report where the users should be able to choose which language, they want to display the reports in.


      We have created translations in SSAS and would like to use these translations depending on which language they choose in Power Bi embedded.


      With your experience do you think this would be possible?
      Thanks in advance
      Best regards
      Brian

      • jcapezzuto's avatar
        jcapezzuto
        Resolver I

        Hi Brian,

        Yes this is definitely possible but you will need multiple versions of your report (one for each language).  Each report can be created to use the appropriate data translations from SSAS, but the dimension and measure names have to be set directly in the report for each language so they appear correctly in column headings etc. 

         

        Please let me know if you have any other questions.

         

        Thanks,

        Jon

    • Anonymous's avatar
      Anonymous
      Not applicable

      I managed to pass language and formatLocale in the embedURL and it works nicely. Though, it is not translating my calendar table - have you had any success with this if you even tried it?

    • Anonymous's avatar
      Anonymous
      Not applicable

      Hi Jon,

      Do you know if the language and formatLocale settings can affect date formats for slicers (e.g. from MM/DD/YYYY to DD/MM/YYYY)? Thanks.

       

      • jcapezzuto's avatar
        jcapezzuto
        Resolver I

        Yes this will work with slicers but you have to select the date formats that are locale sensitive (they begin with an *)