Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
I noticed an underlying problem where the UpdateSettings method exposed by the Javascript library does not actually affect any change to the report specified. I confirmed that the method itself was not failing, just that it essentially wasn’t working. I made sure that I was using the latest version of the library (2.5.0) and even downgraded a minor version to compare and still faced the same issue. I followed the guidelines strictly that were laid out on the Wiki page and tried a few obvious alternatives without any luck. This is in regards to embedding PowerBI in an Iframe.
Can anyone provide feedback on why this might not be working?
Here's a code snippet of the function I was calling:
let embedContainer = $('#reportContainer')[0];
let models = window['powerbi-client'].models;
let defaultLayout = {
displayState: {
mode: models.VisualContainerDisplayMode.Hidden
}
};
let pageSize = {
type: models.PageSizeType.Custom
};
let pageLayout = {
defaultLayout: defaultLayout,
visualsLayout: {}
};
let settings = {
filterPaneEnabled: false,
navContentPaneEnabled: false,
layoutType: models.LayoutType.Custom,
customLayout: {
pageSize: pageSize,
displayOption: models.DisplayOption.FitToPage,
pagesLayout: {
"ReportSection3": pageLayout
}
}
}
report = powerbi.get(embedContainer);
report.updateSettings(settings)
.catch(function (error) {
Log.log(errors);
});
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.