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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Power Apps button to a...
Power Apps
Answered

Power Apps button to aopen an outlook new message with an Excel-type table

(4) ShareShare
ReportReport
Posted on by 818
So I know I can launch the app with this code:
Launch("mailto:recipient@example.com?subject=Email%20Subject&body=This%20is%20the%20email%20body")
But I need something like this
Column1 column2 column3
xxxx yyyyy zzzz
 
copied into the body of the email part. 
Is this possible?
Categories:
I have the same question (0)
  • Verified answer
    stampcoin Profile Picture
    5,058 Super User 2025 Season 2 on at
    Maybe not. Consider using Office365Outlook connector in the app.
    For example, i have a button to send the email.
     
        // 1.  Put your data in a collection, like a form, SharePoint list, etc
    ClearCollect(
        colRows,
        { Column1:"a", Column2:"b", Column3:"c" },
        { Column1:"d", Column2:"e", Column3:"f" }
    );
    
    // 2.  Convert that collection to HTML rows
    Set(
        htmlRows,
        Concat(
            colRows,
            "<tr>" &
                "<td>" & Column1 & "</td>" &
                "<td>" & Column2 & "</td>" &
                "<td>" & Column3 & "</td>" &
            "</tr>"
        )
    );
    
    Set(
        htmlTable,
        "<table border='1'>" &
            "<thead><tr>" &
                "<th>Column 1</th><th>Column 2</th><th>Column 3</th>" &
            "</tr></thead>" &
            "<tbody>" & htmlRows & "</tbody>" &
        "</table>"
    );
    
    // 4.  Send  the e‑mail
    Office365Outlook.SendEmailV2(
        "a@b.com",
        "Subject",
        htmlTable,
        { IsHtml: true }
    );
    
     
    you can add a screen for preview the content  if needed.
     
  • WorkingRicardo Profile Picture
    818 on at
    @stampcoin hey hadn't seen this! Thanks for your reply.
     
    Ohh, so it's not possible? Yeah I tried your code but I was asked expressly that they didn't want for the email to be sent automatically. I'm gonna pitch the preview screen, but I know that will be turned down. 
     
    They need for the new email pop up to show up and want to send the email themselves for possible tweaking of the email. 
     
    Let me know if there's someway :(
  • stampcoin Profile Picture
    5,058 Super User 2025 Season 2 on at
    Understand, I cannot find any doc that mailto accepts html tag. Maybe others have solution/answer.
    Sometimes  say 'No' to the end user, but if they can get budget, that will be different story.😊
     
     
  • WarrenBelz Profile Picture
    153,079 Most Valuable Professional on at
    Just confirming @stampcoin's advice - the output of the mailto: function is interpreted by the Outlook client as plain text, so you have a compromise if you actually want to see the "preview" in Outlook. It is possible that some email clients (mailto: opens the email in the default email client of the user) may support this, but Outlook does not.
    ​​​​​​I use a HTML "preview" and add a Rich Text box with the body pre-filled and then able to be changed. You would have to add your Table before or after this when sending the email as the editor does not allow Tables.

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 721 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 320 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard