<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to get and set parameters on an Embedded Paginated Report in Developer</title>
    <link>https://community.fabric.microsoft.com/t5/Developer/How-to-get-and-set-parameters-on-an-Embedded-Paginated-Report/m-p/3248233#M42781</link>
    <description>&lt;P&gt;EDIT: It appears the preferred way to pass these parameters is via the&amp;nbsp;parameterValues property of&amp;nbsp;IPaginatedReportLoadConfiguration. However, it seems&amp;nbsp;IPaginatedReportLoadConfiguration is not importable from powerbi-client...&lt;/P&gt;&lt;P&gt;&lt;A href="https://learn.microsoft.com/en-us/javascript/api/overview/powerbi/embed-paginated-report" target="_blank" rel="noopener"&gt;https://learn.microsoft.com/en-us/javascript/api/overview/powerbi/embed-paginated-report&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;EDIT2:&amp;nbsp;IPaginatedReportLoadConfiguration is importable from powerbi-client.models.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;private _paginatedReportConfig: models.IPaginatedReportLoadConfiguration = {
        type: 'report',
        id: '',
        embedUrl: undefined,
        tokenType: models.TokenType.Embed,
        accessToken: '',
        parameterValues: [
            { name: 'StartDate', value: '05/01/2023' },
            { name: 'EndDate', value: '05/22/2023' },
            { name: 'OtherParam', value: '86' },
        ],
        settings: {
            commands: {
                parameterPanel: {
                    enabled: this.showParams,
                },
            },
        },
    };&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;ORIGINAL:&lt;/P&gt;&lt;P&gt;&lt;A href="https://learn.microsoft.com/en-us/power-bi/paginated-reports/parameters/pass-report-parameter-url" target="_blank" rel="noopener"&gt;https://learn.microsoft.com/en-us/power-bi/paginated-reports/parameters/pass-report-parameter-url&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I found one solution, passing parameters as query parameters in the EmbedUrl. I need to confirm that their is a way to disable the parameters section of the paginated report. I think it can be done by hiding all the params in Report Builder or maybe with a client-side option.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Below is some basic code appending 3 parameters to the EmbedUrl.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="csharp"&gt;var paginatedReport = pbiClient.Reports.GetReportInGroup(workspaceId, paginatedReportId);

paginatedReport.EmbedUrl += "&amp;amp;rp:StartDate=05%2F01%2F2023";
paginatedReport.EmbedUrl += "&amp;amp;rp:EndDate=05%2F22%2F2023";
paginatedReport.EmbedUrl += "&amp;amp;rp:OtherParameter=99";

 var tokenRequest = new GenerateTokenRequestV2(
	reports: new List&amp;lt;GenerateTokenRequestV2Report&amp;gt;() { new GenerateTokenRequestV2Report(paginatedReportId) },
	datasets: !string.IsNullOrEmpty(paginatedReport.DatasetId) ? new List&amp;lt;GenerateTokenRequestV2Dataset&amp;gt; { new GenerateTokenRequestV2Dataset(paginatedReport.DatasetId) } : null,
	targetWorkspaces: new List&amp;lt;GenerateTokenRequestV2TargetWorkspace&amp;gt;() { new GenerateTokenRequestV2TargetWorkspace(workspaceId) },
	identities: effectiveIdentities
);

pbiClient.EmbedToken.GenerateToken(tokenRequest);&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 23 May 2023 18:10:46 GMT</pubDate>
    <dc:creator>Log4TurtleShell</dc:creator>
    <dc:date>2023-05-23T18:10:46Z</dc:date>
    <item>
      <title>How to get and set parameters on an Embedded Paginated Report</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/How-to-get-and-set-parameters-on-an-Embedded-Paginated-Report/m-p/3244877#M42752</link>
      <description>&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have embedded reports and paginated reports in our website. For the regular reports I set up a bookmarking system using the &lt;A href="https://www.npmjs.com/package/powerbi-client" target="_blank" rel="noopener"&gt;powerbi-client javascript library&lt;/A&gt;&amp;nbsp;to capture and apply bookmarks. I am trying to do something similar for paginated reports. I understand that currently paginated reports are much more limited than regular reports. There is no bookmarking functionality or client-side events for embedded paginated reports, so I am trying to find another way.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have a paginated report with about 10 drop downs and one radio button. I want to give users the ability to save their selections and reapply them. I cannot get a users selected parameters with javascript because the parameters are inside the embedded iframe and&amp;nbsp; &lt;A href="https://developer.mozilla.org/en-US/docs/Web/Security/Same-origin_policy" target="_blank" rel="noopener"&gt;same-origin policy&lt;/A&gt;&amp;nbsp;forbids it.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Does anyone have a solution for this? Is this feature on the roadmap to make paginated reports more feature complete like regular reports?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there a way to send parameter selections with the API request to get the embedded report? I am still looking for a way to do this. If I can do that, then I can probably hide all of the report parameters, and create a UI for the users to select parameters so that my application has control of all the parameters. Of course, I would rather find a simpler solution, but this is my best idea at the moment.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for your time!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;EDIT: It may be helpful to know this is an embed for your customers (app owns data) scenario using an A sku and a Service Principal.&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Fri, 19 May 2023 20:28:33 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/How-to-get-and-set-parameters-on-an-Embedded-Paginated-Report/m-p/3244877#M42752</guid>
      <dc:creator>Log4TurtleShell</dc:creator>
      <dc:date>2023-05-19T20:28:33Z</dc:date>
    </item>
    <item>
      <title>Re: How to get and set parameters on an Embedded Paginated Report</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/How-to-get-and-set-parameters-on-an-Embedded-Paginated-Report/m-p/3248233#M42781</link>
      <description>&lt;P&gt;EDIT: It appears the preferred way to pass these parameters is via the&amp;nbsp;parameterValues property of&amp;nbsp;IPaginatedReportLoadConfiguration. However, it seems&amp;nbsp;IPaginatedReportLoadConfiguration is not importable from powerbi-client...&lt;/P&gt;&lt;P&gt;&lt;A href="https://learn.microsoft.com/en-us/javascript/api/overview/powerbi/embed-paginated-report" target="_blank" rel="noopener"&gt;https://learn.microsoft.com/en-us/javascript/api/overview/powerbi/embed-paginated-report&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;EDIT2:&amp;nbsp;IPaginatedReportLoadConfiguration is importable from powerbi-client.models.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;private _paginatedReportConfig: models.IPaginatedReportLoadConfiguration = {
        type: 'report',
        id: '',
        embedUrl: undefined,
        tokenType: models.TokenType.Embed,
        accessToken: '',
        parameterValues: [
            { name: 'StartDate', value: '05/01/2023' },
            { name: 'EndDate', value: '05/22/2023' },
            { name: 'OtherParam', value: '86' },
        ],
        settings: {
            commands: {
                parameterPanel: {
                    enabled: this.showParams,
                },
            },
        },
    };&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;ORIGINAL:&lt;/P&gt;&lt;P&gt;&lt;A href="https://learn.microsoft.com/en-us/power-bi/paginated-reports/parameters/pass-report-parameter-url" target="_blank" rel="noopener"&gt;https://learn.microsoft.com/en-us/power-bi/paginated-reports/parameters/pass-report-parameter-url&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I found one solution, passing parameters as query parameters in the EmbedUrl. I need to confirm that their is a way to disable the parameters section of the paginated report. I think it can be done by hiding all the params in Report Builder or maybe with a client-side option.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Below is some basic code appending 3 parameters to the EmbedUrl.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="csharp"&gt;var paginatedReport = pbiClient.Reports.GetReportInGroup(workspaceId, paginatedReportId);

paginatedReport.EmbedUrl += "&amp;amp;rp:StartDate=05%2F01%2F2023";
paginatedReport.EmbedUrl += "&amp;amp;rp:EndDate=05%2F22%2F2023";
paginatedReport.EmbedUrl += "&amp;amp;rp:OtherParameter=99";

 var tokenRequest = new GenerateTokenRequestV2(
	reports: new List&amp;lt;GenerateTokenRequestV2Report&amp;gt;() { new GenerateTokenRequestV2Report(paginatedReportId) },
	datasets: !string.IsNullOrEmpty(paginatedReport.DatasetId) ? new List&amp;lt;GenerateTokenRequestV2Dataset&amp;gt; { new GenerateTokenRequestV2Dataset(paginatedReport.DatasetId) } : null,
	targetWorkspaces: new List&amp;lt;GenerateTokenRequestV2TargetWorkspace&amp;gt;() { new GenerateTokenRequestV2TargetWorkspace(workspaceId) },
	identities: effectiveIdentities
);

pbiClient.EmbedToken.GenerateToken(tokenRequest);&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 23 May 2023 18:10:46 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/How-to-get-and-set-parameters-on-an-Embedded-Paginated-Report/m-p/3248233#M42781</guid>
      <dc:creator>Log4TurtleShell</dc:creator>
      <dc:date>2023-05-23T18:10:46Z</dc:date>
    </item>
  </channel>
</rss>

