Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
Hello,
We are using JavaScript API to integrate the Power BI reports in our .net web application. As provided in the demo (https://microsoft.github.io/PowerBI-JavaScript/demo/code-demo/index.html#), we are using div to render reports/dashboards. We are supposed to define the height of the reports/dashboards in pixels but we want them to use the available space on being rendered.
Is there any way to fit the report/dashboard to our windows?
Thanks
Solved! Go to Solution.
@SFerro wrote:
Hello,
We are using JavaScript API to integrate the Power BI reports in our .net web application. As provided in the demo (https://microsoft.github.io/PowerBI-JavaScript/demo/code-demo/index.html#), we are using div to render reports/dashboards. We are supposed to define the height of the reports/dashboards in pixels but we want them to use the available space on being rendered.
Is there any way to fit the report/dashboard to our windows?
Thanks
You could set fitToWidth in the embedding configuration.
var config = { type: 'dashboard', tokenType: models.TokenType.Embed, accessToken: accessToken, embedUrl: embedUrl, pageView: "fitToWidth", id: embedDashboardId };
@SFerro wrote:
Hello,
We are using JavaScript API to integrate the Power BI reports in our .net web application. As provided in the demo (https://microsoft.github.io/PowerBI-JavaScript/demo/code-demo/index.html#), we are using div to render reports/dashboards. We are supposed to define the height of the reports/dashboards in pixels but we want them to use the available space on being rendered.
Is there any way to fit the report/dashboard to our windows?
Thanks
You could set fitToWidth in the embedding configuration.
var config = { type: 'dashboard', tokenType: models.TokenType.Embed, accessToken: accessToken, embedUrl: embedUrl, pageView: "fitToWidth", id: embedDashboardId };
User | Count |
---|---|
14 | |
4 | |
2 | |
1 | |
1 |
User | Count |
---|---|
22 | |
3 | |
3 | |
2 | |
2 |