Quantcast
Channel: All Developer posts
Viewing all articles
Browse latest Browse all 48104

how to set page & filter to embedded report?

$
0
0

Hi, I want to ask some questions.

first using this guide
https://powerbi.microsoft.com/en-us/documentation/powerbi-developer-integrate-report/

My application already work displaying power bi report

 

How to set the page & filter to that report ?

I'm using this code in my script

function postActionLoadReport() {
                // Construct the push message structure
                var m = {
                    action: "loadReport",
                    accessToken: '@TempData["accessToken"]',
                    oDataFilter: "MyTable/Location eq 'abc'",
                    pageName : 'Page 2'
                };
                message = JSON.stringify(m);
                // push the message.
                iframe = document.getElementById('iFrameEmbedReport');
                iframe.contentWindow.postMessage(message, "*");;
                iframe.contentWindow.print();
            }

but it didn't display the 'Page 2' and no filter selected.

 

And my second question is

how to set multiple filter?, so the report programmatically load the filters

 

PS: I'm new in javascript programming. Any help & references is appreaciated

Thanks.


Viewing all articles
Browse latest Browse all 48104

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>