Forum Discussion

Praneshpk22's avatar
Praneshpk22
New Member
2 years ago

How to Edit and Save Power BI Report embedded in Sharepoint online.

Hi Team,

 

I want to edit and save a Power BI report which is embedded in Sahrepoint Online. What is the possible way to do this?

I have tried Sandbox developer Playground. In that i'm able to get the edit and save option Javascript Code, but no idea how to use that in Sharepoint online.

Thankyou in advance

2 Replies

  • Can you use the web connection in Power BI Desktop to connect to the Sharepoint site. Then Edit the share point URL up to ?. Remove the ? too and try connecting to the share point site if that is what you want to achieve. You will be able to connect and have the report PBIX format.

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi Praneshpk22 ,

    Load your existing report in Edit mode. The report must be embedded in the same way the application embeds a regular report, and the view mode must be in Edit. Make sure that you set the parameter to , and that you have the right client permissions.

    let config = {
        type: 'report',
        tokenType: models.TokenType.Aad or models.TokenType.Embed,
        accessToken: YourAccessToken,
        embedUrl: YourEmbedUrl,
        id: YourEmbedReportId,
        permissions: models.Permissions.All,
        viewMode: models.ViewMode.Edit,
    };
    
    // Grab the reference to the div HTML element that will host the report
    let embedContainer = $('#embedContainer')[0];
    
    // Embed report
    let report = powerbi.embed(embedContainer, config);

    Here is the official link:

    Create, edit, and save an embedded report | Microsoft Learn

    Best Regards,

    Xianda Tang

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.