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 / Outlook Connector - Di...
Power Apps
Answered

Outlook Connector - Display Image in the body of the email

(0) ShareShare
ReportReport
Posted on by 1,712

Hello everyone,

I would like to display a png image that is uploaded to my canvas app in the email body message that will be sent using the outlook connector within the app.

I have tried to convert the png image to base64 that is defined in variable and after that, I passed this variable in the body of the email inside the HTML source code as below, but unfortunately, it is not working and displaying the image in the email it is showing a blank content:

 

Set(PenVar, JSON( Image.Image,JSONFormat.IncludeBinaryData ) );
Office365Outlook.SendEmailV2("test@microsoft.com","test","<img src='data&colon;image/png;base64,"&PenVar&"' alt='TestImg' width='500' height='600'>",{IsHTML:true})

 

LogoImageData.png
BlankEmail.png

What I am doing wrong? Could you please provide an example and the corrected formula that will make it work?

Any help is highly appreciated.
Thank you!

Categories:
I have the same question (0)
  • TheRobRush Profile Picture
    11,128 Moderator on at

    I could be wrong, as it's been a while since I looked into this, but I believe images can not be sent embedded in the email body only as attachments using the built in outlook connector. You can still do it, but you would push the email portion out to a Microsoft flow using powerautomate.

     

    Someone feel free to correct me.

  • EBMRay Profile Picture
    1,712 on at

    Hi @TheRobRush ,
    Thank you for your reply.

    I watched different youtube videos and I noticed that various people were able to send embedded images in the email but with a hardcoded base64 code used in the HTML code. My requirement for this app is to use Power Automate to send emails.

    Let us wait for additional answers.

    Best regards,
    Julien

  • Verified answer
    TheRobRush Profile Picture
    11,128 Moderator on at

    Alright so I got it working on my end.

    In this example I have an upload image control, and the image portion of it is titled UploadedImage2

    Set(varImage,JSON(UploadedImage2.Image,IncludeBinaryData));
    Office365Outlook.SendEmailV2("No@Email.com","Email With Image", "<img src="&varImage&">")

     

    that should make your code something like

    Set(PenVar,JSON(Image.Image,IncludeBinaryData));
    Office365Outlook.SendEmailV2("test@microsoft.com","test", "<img src="&PenVar&">")
  • EBMRay Profile Picture
    1,712 on at

    Hello @TheRobRush ,

    I also got it working on my end based on the formula that you have provided.

    Thank you for your assistance.

    Best regards,
    Julien

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

Season of Sharing Community Challenge Launch!

Jump in, show your community spirit, and win prizes!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Valantis Profile Picture

Valantis 424

#2
WarrenBelz Profile Picture

WarrenBelz 355 Most Valuable Professional

#3
11manish Profile Picture

11manish 290

Last 30 days Overall leaderboard