Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Download in PDF

Hi All

 

Microsoft has released the option to download report in PDF in PowerBI Embedded. However, they has provided only C# code. ANd, for my project, I have required the Java Script code. Can anyone suggest me, how I can get the JS code. Or I can translate C# code into Java Script.

 

3 REPLIES 3
Jayendran
Solution Sage
Solution Sage

Hi @Anonymous ,

 

Basically you have to use the exporttofileingroup REST API

 

https://docs.microsoft.com/en-us/rest/api/power-bi/reports/exporttofileingroup

 

The C# Code/Dotnet SDK is just a abstraction layer which internally uses the same export api. So you can use the raw api in your javascirpt rather than a C# code/any sdk

Anonymous
Not applicable

@Jayendran

 

Thanks for your reponse. It's great help for me. It will good, if you can share some example file for the same

 

Kind Regards

Ashwani

Hi @Anonymous ,

 

I'm not much into javascript, however I can give you some links handy

 

https://stackoverflow.com/questions/47194412/node-js-app-integration-with-power-bi-rest-api

 

With the above link you just need to replace the exisiting API with the export API.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.