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

We've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now

Reply
benw101010
New Member

API Export with captured bookmark state only has current page filters

When I pass the bookmark state to request PowerBIClient.Reports.ExportToFileInGroup, only the filters / slicers for the current page are applied to resulting export (powerpoint).

 

In javascript, I'm capturing the bookmark from an embedded PBI report...

 

.report.bookmarksManager.capture({
allPages: true,
personalizeVisuals: true
})

 

Please advise if there is a way to get filters from all pages in an export report.

 

1 ACCEPTED SOLUTION

I found my issue - I needed to update powerbi.js.  Exported pdf now has page level filters from captured bookmark.

 

https://github.com/microsoft/PowerBI-JavaScript/tree/master/dist

View solution in original post

4 REPLIES 4
AmosHersch
Microsoft Employee
Microsoft Employee

Not sure why it's not working. Might be a bug on Power BI side but requires investigation.

Since you are already using Power BI JS to capture the bookmark I would try to apply the captured bookmark state and see if it works or not.

I found my issue - I needed to update powerbi.js.  Exported pdf now has page level filters from captured bookmark.

 

https://github.com/microsoft/PowerBI-JavaScript/tree/master/dist

benw101010
New Member

yes defaultBookmark.  c# server side code...

 

var powerBIReportExportConfiguration = new PowerBIReportExportConfiguration
{
Settings = new ExportReportSettings
{
Locale = "en-us",
},
// Note that page names differ from the page display names
// To get the page names use the GetPages REST API
Pages = pageNames?.Select(pn => new ExportReportPage(pn)).ToList(),
DefaultBookmark = new PageBookmark(null, bookmark.state),
Identities = identities
};

var exportRequest = new ExportReportRequest
{
Format = format,
PowerBIReportConfiguration = powerBIReportExportConfiguration,
};

// The 'Client' object is an instance of the Power BI .NET SDK
var export = await client.Reports.ExportToFileInGroupAsync(groupId, reportId, exportRequest);
// Save the export ID, you'll need it for polling and getting the exported file

var result = new ExportRequest()
{
ExportId = export.Id,
ReportName = report.Name,
ReportId = reportId,
GroupId = groupId
};
return result;

 

AmosHersch
Microsoft Employee
Microsoft Employee

Hi @benw101010 ,

 

Can you please share how the request to the API looks like?

Do you just pass the captured bookmark state in the defaultBookmark parameter?

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.