godd4k's avatar
godd4k
Regular Visitor
8 years ago
Status:
Accepted

Dashboard Embed loaded event not emitted.

I am using the PowerBI JavaScript Client to embed dashboards into my service, I can see the dashboard that I am trying to embed, however the "loaded" event never seems to be triggered.

Here's my code (well a snippet anyway)

dashboard = powerbi.embed(fullscreen, embedConfiguration);

Both fullscreen and the config are legit (don't forget I can see my dashboard, it works!) on the lines directly below I have

dashboard.on('loaded', function (e) {
  console.log('Dashboard Loaded', e);
});

dashboard.on('error', function (e) {
  console.log('Dashboard Errored', e);
});

But the "loaded" callback is never run.. Now for humour I found as many events as I possibly could and added callbacks just to log out which events, if any.. I could trigger, I've tried "rendered", "saved", "saveAsTriggered", "dataSelected" & "tileClicked".. Only tileClicked has been observed as working, so I wondered if anybody could shed some light..

I only require the loaded or rendered event.. How?

Side note: I have found that there is an unresolved promise inside the service value of the object returned upon embed, in my instance..

// Promise can be found on..
dashboard.service.wpmp.pendingRequestPromises

 

4 Comments