cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Kudo Kingpin
Kudo Kingpin

how to send an email or send data to powerapps from gallery items or collection

I have a dynamically created collection based on timer job(400 items) collection gets into gallery for display purpose.

Now I want to send this collection(3 columns with 400 items) to email and also to power.run(this data).

How do I do that?

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support
Community Support

Hi @AmitLoh-Powerap,

 

So here you would like to send the table value using the SendEmail function, or using the Flow under PowerApps?

For the SendEmail function, currently it only accept string value with the parameter"TO, Subject, or Body", so if we would like to send Email with this function, we need to add a forall function, which means for each records (should be 400 times), it will send an email;

For the Flow, if the collection is generated directly from data source, then we could just make the flow trigger from PowerApps, after that, add an action to Get Rows (If this is available from your datasource ) from the data source directly from Microsoft Flow, specify the Value Content from the Get Rows action in the Send Email Body part in send Email action, after that, just add the flow.run() with a button Onselect property in PowerApps, this should make the send email work.

If I have any misunderstandings, please post back.

Regards

Community Support Team _ Michael Shao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
Community Support
Community Support

Hi @AmitLoh-Powerap,

 

So here you would like to send the table value using the SendEmail function, or using the Flow under PowerApps?

For the SendEmail function, currently it only accept string value with the parameter"TO, Subject, or Body", so if we would like to send Email with this function, we need to add a forall function, which means for each records (should be 400 times), it will send an email;

For the Flow, if the collection is generated directly from data source, then we could just make the flow trigger from PowerApps, after that, add an action to Get Rows (If this is available from your datasource ) from the data source directly from Microsoft Flow, specify the Value Content from the Get Rows action in the Send Email Body part in send Email action, after that, just add the flow.run() with a button Onselect property in PowerApps, this should make the send email work.

If I have any misunderstandings, please post back.

Regards

Community Support Team _ Michael Shao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Can you explain this answer in a little more detail? I do not follow after the 400 emails... How would you send just one email with all 400 rows in the body of the email....

Power Participant
Power Participant

Hi!

 

I can answer you regarding the email part, so here's my thought about that part.

 

Since you want to mail one email-address with the content of the collection you can use Office365.SendEmail and Concat. Concat works with collections, so it will be quite easy:


Office365.SendEmail("address@goes.here", "topic", "Start of message, collection to follow: " & Concat(collectionname, columns1 & " " & column2 & " " & column3 & char(13)))


Depending on the values in column1..3 you might want to do some formatting using Text(column1, "formatting characters goes here"), and perhaps you want some other delimiter between the fields other than a space. The char(13) on the end gives you a new line for each item; just remove it if you don't need that.

 

Hope that helps, best of luck!

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

News & Announcements

Community Blog

Stay up tp date on the latest blogs and activities in the community News & Announcements.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Community Highlights

Community Highlights

Check out the Power Platform Community Highlights

Top Solution Authors
Top Kudoed Authors
Users online (13,019)