cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
anthjanz
Helper II
Helper II

Format powerapp form data in a table in an email

Hi, 

Has anyone been able to format powerapp form data in a table in an email?

 

Thank you

1 ACCEPTED SOLUTION

Accepted Solutions
v-qiaqi-msft
Community Support
Community Support

Hi @anthjanz,

Do you want to send data from the form into a html table with an email?

Could you please share a bit more about your scenario, do you have an edit form to submit data?

 

Actually, it is easy to achieve this in Power Apps, all your need is to add a HTML text input, please check as below.

1). If you have an edit form to submit data, please set the submit button as below:

SubmitForm(Form4);
Office365Outlook.SendEmailV2(
    "
QiQiao@xxx.onmicrosoft.com",
    "Notify",
    HtmlText4.HtmlText
)

2). Add a Html Text input and set the HtmlText property as below:

"<strong> Information: </strong>" & "<table width='100%' border='1' cellpadding='5' style='border:1px solid black; border-collapse:collapse'>" & "<tr style='background-color:#efefef'>
         <th>Title</th> <th> Name </th><th> Score </th>
     </tr>" & "<tr>
     <td>" & Form4.LastSubmit.Title & " </td>
        
              <td>" & Form4.LastSubmit.Name & " </td>
              <td>" & Form4.LastSubmit.Score & " </td> 
              
     </tr>" & "</table>"

Note that Form4 is my edit form.

vqiaqimsft_0-1645779086709.png

Here is the test result:

vqiaqimsft_1-1645779151707.png

 

 

Best Regards,
Qi

View solution in original post

5 REPLIES 5
Digital
Super User
Super User

You can do this using the HTML text control. Create a HTML template that you inject your form values into. You can then use the HTML text as the content for your email.

anthjanz
Helper II
Helper II

Sorry Digital, I'm a new to all this. Are you talking about something that can be done in Powerapps?
is there any code you could post?

Cheers

Digital
Super User
Super User

@anthjanz ,

 

Yes in Power Apps.

 

Your best bet would be to watch this video. Shane Young's YouTube channel is a great resource for starting out with this stuff and he explains it way better than I could here.

 

https://www.youtube.com/watch?v=vpYkOccwn4Y&ab_channel=ShaneYoung

v-qiaqi-msft
Community Support
Community Support

Hi @anthjanz,

Do you want to send data from the form into a html table with an email?

Could you please share a bit more about your scenario, do you have an edit form to submit data?

 

Actually, it is easy to achieve this in Power Apps, all your need is to add a HTML text input, please check as below.

1). If you have an edit form to submit data, please set the submit button as below:

SubmitForm(Form4);
Office365Outlook.SendEmailV2(
    "
QiQiao@xxx.onmicrosoft.com",
    "Notify",
    HtmlText4.HtmlText
)

2). Add a Html Text input and set the HtmlText property as below:

"<strong> Information: </strong>" & "<table width='100%' border='1' cellpadding='5' style='border:1px solid black; border-collapse:collapse'>" & "<tr style='background-color:#efefef'>
         <th>Title</th> <th> Name </th><th> Score </th>
     </tr>" & "<tr>
     <td>" & Form4.LastSubmit.Title & " </td>
        
              <td>" & Form4.LastSubmit.Name & " </td>
              <td>" & Form4.LastSubmit.Score & " </td> 
              
     </tr>" & "</table>"

Note that Form4 is my edit form.

vqiaqimsft_0-1645779086709.png

Here is the test result:

vqiaqimsft_1-1645779151707.png

 

 

Best Regards,
Qi

Thanks Qi, that was very helpful!

 

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (3,298)