Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more.
Get startedGrow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.
Hello! I'm using the powerbi-client library to create a new report in an container. I am able to use the createReport method to create reports but not paginated reports. This is the code I'm using to create reports:
import * as pbi from "powerbi-client";
const powerbi = new pbi.service.Service(
pbi.factories.hpmFactory,
pbi.factories.wpmpFactory,
pbi.factories.routerFactory
);
let embedCreateConfiguration = {
tokenType: 1,
accessToken: "<access_token>",
embedUrl: "https://app.powerbi.com/reportEmbed",
datasetId: "<dataset_id>",
};
let embedContainer = document.getElementById("embed");
let report = powerbi.createReport(
embedContainer,
embedCreateConfiguration
);
{"datasets": [{"id": "<dataset_id>"}, "targetWorkspaces": [{"id": "<workspace_id>"}]]
Solved! Go to Solution.
Hi @ys01
here is a sample attempt i made to connect to JS script.
var embedConfiguration = {
type: 'report',
accessToken: '<embed_token>',
embedUrl: '<report_url>',
tokenType: models.TokenType.Embed,
settings: {
filterPaneEnabled: false,
navContentPaneEnabled: false
}
};
var reportContainer = document.getElementById('reportContainer');
var report = powerbi.embed(reportContainer, embedConfiguration);
Did I answer your question? Mark my post as a solution! Appreciate your Kudos !!
Hi @ys01
here is a sample attempt i made to connect to JS script.
var embedConfiguration = {
type: 'report',
accessToken: '<embed_token>',
embedUrl: '<report_url>',
tokenType: models.TokenType.Embed,
settings: {
filterPaneEnabled: false,
navContentPaneEnabled: false
}
};
var reportContainer = document.getElementById('reportContainer');
var report = powerbi.embed(reportContainer, embedConfiguration);
Did I answer your question? Mark my post as a solution! Appreciate your Kudos !!
User | Count |
---|---|
12 | |
9 | |
5 | |
4 | |
1 |
User | Count |
---|---|
19 | |
15 | |
3 | |
2 | |
2 |