Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes! Register now.

Reply
pyskaty
Frequent Visitor

Export to excel with RLS and USERCULTURE (power bi embedded)

Hi guys,

I have a strange problem with passing culture to "export to excel" function in power bi embedded scenario.

 

Environment: 

Report published to service and displayed on my web using embed scenario. I'm using RLS (one of rules uses USERCULTURE() to filter some data). I'm passing culture when embedding report in JavaScript

const config: any = {
      type: 'report',
      tokenType: pbi.models.TokenType.Embed,
      accessToken: accessToken.token,
      embedUrl: accessToken.embedUrl,
      pageView: 'fitToWidth',
      id: accessToken.reportId,
      permissions: pbi.models.Permissions.All,
      filters,
      settings: {
        filterPaneEnabled: false,
        navContentPaneEnabled: false,
        background: pbi.models.BackgroundType.Transparent,
        localeSettings: {
          language: this.userSettings.language,  // en, es, ...
          formatLocale: this.userSettings.language,
        }
      },
    };

return new pbi.service.Service(pbi.factories.hpmFactory,
      pbi.factories.wpmpFactory, pbi.factories.routerFactory)
      .embed(element, config) as Report;


Everything work fine until user try to export data to excel (using context menu on visual). Then culture is always set to 'en-US' regarding user's locale and sent config. 

 

Is there any way to configure "export to excel" to use given culture and not default one? Thanks in advance. 

 

3 REPLIES 3
Julien1983
New Member

Hello, 

We have the same problem.

Have you found a solution or created a ticket for this bug?

Regards

Anonymous
Not applicable

Hi @pyskaty 

I didnt embed report in JavaScript like you did, so I dont quite understand the result you provided .

In Power BI service , we set the language in Settings, and there seems to be no language setting for export data in visual .

Ailsa-msft_0-1621586653240.png

Maybe you can try to change the language setting in the Settings, and then look at the result ?

 

Best Regards

Community Support Team _ Ailsa Tao

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi @Anonymous 

Setting static language in power bi servcie oraz report will not resolve my problem. I have multi language environment where users use different cultures (en-US, pl-PL and so on). I pass culture as parameter when embedding report in my app and it works - except 'export to excel' - where culture is alwasy set to en-US.

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors