web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / How to email a PDF fil...
Power Apps
Unanswered

How to email a PDF file using SendMail?

(1) ShareShare
ReportReport
Posted on by

Please, can anyone in the community provide a little suggestion on how to email a PDF file using SendMail?

 

Button OnSelect: Office365.SendEmail(User().Email,"Your Package is on its Way!",txtEmailBody,{Importance: Normal, IsHtml:true, {Attachments:Table({Name:"file1.pdf", ContentBytes:??????.???, '@odata.type':""}) });

 

1) I can't work out what the ContentBytes should be for a PDF;

2) Where should I put the "file1.PDF" so that SendMail can find it?

 

All of the excellent examples I've found demonstrate how to send a pic from a camera.

 

Thank you in advance.

Chris

Categories:
I have the same question (0)
  • v-micsh-msft Profile Picture
    Microsoft Employee on at

    Hi @ChrisChong,

     

    I think the issue here is there is no file uploader available in PowerApps.

    So it is not available for PowerApps to get the actual PDF file content.

     

    For a workaround, read the following blog and see if it helps in your scenario:

    Convert PowerApps data to PDF and send it as an email

     

    Regards,

    Michael

  • ChrisChong Profile Picture
    on at

    Thank you for your response. You could be right what you describe as an issue.  However, the 'workaround' you suggest does not work for me. I have a PDF I would like to include in an email generated by my App.

     

    Perhaps the lack of a workable response is an indication that it cannot currently be done?

     


    @v-micsh-msft wrote:

    Hi @ChrisChong,

     

    I think the issue here is there is no file uploader available in PowerApps.

    So it is not available for PowerApps to get the actual PDF file content.

     

    For a workaround, read the following blog and see if it helps in your scenario:

    Convert PowerApps data to PDF and send it as an email

     

    Regards,

    Michael


     

  • seadude Profile Picture
    1,855 on at

    Good question! What is the data source (where are you getting this PDF)?

  • ChrisChong Profile Picture
    on at

    Thanks for asking. The source of my PDF: SharePoint.

  • PK_Hong Profile Picture
    337 on at

    Hi @ChrisChong

     

    Just wonder, can you Launch(email) and then attach PDF out of PowerApps?

    I know this is not the right method, but at least a workaround, if you wish to.

    Thanks

  • ChrisChong Profile Picture
    on at

    Thanks for thinking about this. It is the 'workaround' I've resorted to: SendMail to the current user who then has to manually attach the PDF and resend. Not really elegant, is it, not to mention error prone--since the App is even more dependent on user.

     

    It's hard to believe that this is such an unusual request--attaching a PDF in much the same way one might attach a .jpg.  But there it is. I am confident that the PowerApps gods are working feverishly on a good solution--but there are probably many other "good" ideas on which they work.

     

    Thanks for your help.  And to all the others who have applied some thought to this current PowerApp deficiency.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 525 Most Valuable Professional

#2
Haque Profile Picture

Haque 273

#3
Kalathiya Profile Picture

Kalathiya 232 Super User 2026 Season 1

Last 30 days Overall leaderboard