Forum Discussion

AndreasAristo's avatar
AndreasAristo
Regular Visitor
6 years ago

Automatic report refresh and send report as PDF

Hi,

 

I have a Power BI pro license and plan to use a gateway to update a report on a daily basis. I would then like to automatically refresh a report and then send a PDF export of the report to 5-10 pre-defined e-mail adresses every day. Is this posssible?

 

Thanks, 

Andreas

9 Replies

  • AndreasAristo check this video

     

    I would  Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos whoever helped to solve your problem. It is a token of appreciation!

    • AndreasAristo's avatar
      AndreasAristo
      Regular Visitor

      Would it be possible to send a PDF version of the report with the subscription? Some of the members doesnt have Power BI and would like to see a static PDF version of the report instead

       

      Thanks

      • parry2k's avatar
        parry2k
        Icon for Super User rankSuper User

        AndreasAristo maybe you want to use RestAPI to create PDF and then send it by email. See this post.

         

        I would  Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos whoever helped to solve your problem. It is a token of appreciation!

  • v-xicai's avatar
    v-xicai
    Icon for Community Support rankCommunity Support

    Hi AndreasAristo ,

     

    >> I would then like to automatically refresh a report and then send a PDF export of the report to 5-10 pre-defined e-mail adresses every day.

     

    For demand automatically refreshing a report,  you may set schedule refresh, see more details :Configure scheduled refresh .

     

    While it is not supported to automatically send PDF export of refreshed report email in in Power BI currently . There is an idea about this issue, please vote it up, Scheduling the dashboard reports into shared location or email by exporting into pdf/excel,  and you can add your comments there to improve Power BI and make this feature coming sooner.

     

    Best Regards,

    Amy 

     

    Community Support Team _ Amy

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

  • Anonymous's avatar
    Anonymous
    Not applicable

    It's a long time since this original post now and this may come too late, but I think I found a solution to this today.  There may also be less convoluted ways to do this.

     

    Here's the overview.

    1) Firstly, I created a simple measure in my Power BI report which indicated whether the report had been refreshed on that day or not.  It gave a 1 if it had been refreshed and a 0 if it had not been refreshed.

     

    2) I then created a Power BI metric and pointed the "current value" to my 1 or 0 measure.

     

    3) After this, I created my Power Automate flow and used the "when current value of a goal changes" Power BI goals connector to point to my Metrics scorecard / metric.

     

    4) Following this, I used the "get a goal" Power BI goals connector to get the specific current value of the goal - i.e. 1 and 0.  I then added a condition to check if the goal current value was 1 or 0, and if it was 1, then it would trigger the "Export to File for Power BI reports" connector and "Send email" processes.

     

    This works well because it only runs if both of the following are true:

    - The goal has been updated (i.e. changed from 0 ->1 or 1->0) AND

    - The value is 1 (i.e. the data was updated today).

     

    Let me know if this helps. I can provide more detail if needed.

    • Anonymous's avatar
      Anonymous
      Not applicable

      Further to this, I've now created a full blog post about this topic: robhawkerdata.com/2022/10/31/automatic-power-bi-report-distribution-after-dataset-refresh/

       

      The blog provides a slightly different solution to the one I originally proposed.  I think its easier / more robust.