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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Export to file and dynamic bind dataset

I'm using PowerBI embeded to reports, I have multiple datasets for the same report and use dynamic binding  at display depending on the user. (https://azure.microsoft.com/en-gb/updates/power-bi-embedded-dynamic-binding/)

 

I want to export these reports to pdf/pptx and I'm using the ExportReport command in the rest API (https://docs.microsoft.com/en-us/rest/api/power-bi/reports/exportreportingroup). I can see no way to set the dataset to bind.

 

Is the only option to rebind the report before exporting? If I do that do I have to wait for the export to complete before i export the next if i need to rebind again, effectively queuing all the requests?

 

thanks

6 REPLIES 6
Anonymous
Not applicable

This should be possible now for certain file types (I tested using PDF).

 

The Export To File In Group endpoint now supports a datasetToBind field:

Reports - Export To File In Group - REST API (Power BI Power BI REST APIs) | Microsoft Learn

There seems to be a similar field for Export to File:

Reports - Export To File - REST API (Power BI Power BI REST APIs) | Microsoft Learn

 

This can be used to specify the dataset ID that you want to dynamically bind your report to. I have tested Export To File In Group with a dataset that is in a different workspace to my report and the API call was able to resolve the workspaceId of the dataset automatically. 

 

Keep in mind that you may need to update your Power BI client library in order to access this field. I am using the .NET client and needed to update to version 4.10.0:

 NuGet Gallery | Microsoft.PowerBI.Api 4.10.0

Does this really work? Because I receive a Report with "Something's wrong with one or more fields" when I try to do this.

Anonymous
Not applicable

@Anonymous , @annwallinger have you managed to solve this one?

We are facing the same issue and got no clue to move on.

Microsoft, please help.

This it currently not possible. The report is always exported with the original dataset it's bound to.

Such a support might be added in the future for "Export to File" REST API (export to PDF/PPTX/PNG). I don't know if it will be supported for export to PBIX.

Anonymous
Not applicable

Thank you Amos, for your response.

annwallinger
Advocate I
Advocate I

@Anonymous did you ever sort this out? I need to do the same thing and have the same question you raised.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.