Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

286
Views
How to download Power BI Embed Report to PDF using Js?

So I want to generate my PowerBI dash to pdf on my website, and I show my powerBI dash by using iframe embed code like this :

I wrap the iframe code by :

                <!-- Page Heading -->
                <div class="d-sm-flex align-items-center justify-content-between mb-4" >
                    <h1 class="h3 mb-0 text-gray-800">Averagion Dashboard</h1>
                            <button onclick="generatePDF()" class="d-none d-sm-inline-block btn btn-sm btn-primary shadow-sm">
                                <i class="fas fa-download fa-sm text-white-50"></i> Generate Report</a>
                            </button>
                </div>

here is the the header script :

here is the js file : function generatePDF(){ const element = document.getElementById("reporttt");

html2pdf()
.from(element)
.save();

}

when the button is clicked, the pdf file that downloaded are empty page, how can I resolve this ?

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!