cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Helper III
Helper III

If Formula in E-mail Body

 Dear All,

 

I have a powerapps application which has some e-mail flows behind. I stuck at if condition into e-mail body. More details:

E-mail body should be dynamic based on the selections. For instance:

- if 3 plants goods will be loaded, i need to show 3 destinations detials in the e-mail

- if 2 plants goods than ony 2 destination details should appear.

 

Colums belong to a Sharepoint list.

Since i am pretty new for flow, can i ask your support?

Thanks

 

 

 

2020-06-08 23_24_37-Search.png

 

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Super User II
Super User II

Re: If Formula in E-mail Body

@Ogun_ustun 

 

In the Power Automate, create a variable varDestination to store HTML content for destination information.

Then, place a Switch action with check for Destination value.

 

If 1, set variable varDestination  with one destination information.

If 2, set variable varDestination  with two destinations information.

If 3, set variable varDestination with three destinations information.

 

In the Send Email action, replace all the destination HTML tags with the variable varDestination.

 

Regards

Krishna Rachakonda

If this reply helped you to solve the issue, please mark the post as Accepted SolutionMarking this post as Accepted Solution, will help many other users to use this post to solve same or similar issue without re-posting the issue in the group. Saves a lot of time for everyone.

View solution in original post

4 REPLIES 4
Highlighted
Super User II
Super User II

Re: If Formula in E-mail Body

@Ogun_ustun 

 

You have multiple options:

 

Option #1: Create a Switch action. Based on the condition, you can send email. This option gives you more flexibility to customize the email but it uses more Send Email actions. (Important Note: More actions, more API calls)

 

Option #2: We can also write expressions to suite the needs in the email body. 

 

Please let me know if you have further questions.

 

Regards

Krishna Rachakonda

If this reply helped you to solve the issue, please mark the post as Accepted SolutionMarking this post as Accepted Solution, will help many other users to use this post to solve same or similar issue without re-posting the issue in the group. Saves a lot of time for everyone.
Highlighted
Super User II
Super User II

Re: If Formula in E-mail Body

@Ogun_ustun 

 

If you are calling the flow from Power App, you can pass the parameter from the Power App.

 

You can construct the parameter based on 3 or 2 and send one string of information. 

 

You can directly embed the parameter within the email. You may not need any logic within the flow as the logic can be handled within the Power App.

 

Regards

Krishna Rachakonda

If this reply helped you to solve the issue, please mark the post as Accepted SolutionMarking this post as Accepted Solution, will help many other users to use this post to solve same or similar issue without re-posting the issue in the group. Saves a lot of time for everyone.
Helper III
Helper III

Re: If Formula in E-mail Body

@rsaikrishnathanks for your quick reply.

Do you have an sample flow for this? or screenshot that i can try so?

Since i am pretty new for the flow, i can not solve the puzlle easly 😞

BR

Ogun

Highlighted
Super User II
Super User II

Re: If Formula in E-mail Body

@Ogun_ustun 

 

In the Power Automate, create a variable varDestination to store HTML content for destination information.

Then, place a Switch action with check for Destination value.

 

If 1, set variable varDestination  with one destination information.

If 2, set variable varDestination  with two destinations information.

If 3, set variable varDestination with three destinations information.

 

In the Send Email action, replace all the destination HTML tags with the variable varDestination.

 

Regards

Krishna Rachakonda

If this reply helped you to solve the issue, please mark the post as Accepted SolutionMarking this post as Accepted Solution, will help many other users to use this post to solve same or similar issue without re-posting the issue in the group. Saves a lot of time for everyone.

View solution in original post

Helpful resources

Announcements
FirstImage

Microsoft Ignite 2020

Check out the announcement of Power Platform content at Microsoft Ignite!

thirdImage

Experience what's new for Power Automate

Join us for an in-depth look at the new Power Automate features and capabilities at the free Microsoft Business Applications Launch Event.

firstImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

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