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

When an item is modified on a specific column send an email with certain info

This flow wont work for me, I get an error on my expression

 

The expression i've added is:

empty(triggerBody()?['Tekniker som sover'])

 

The column "Tekniker som sover" is a person or group column where you can add several people, but when I add that column in "send an email" the "apply to each" shows up. How do I get rid of that?

 

 

 

flowproblem sovtid.png

7 REPLIES 7
Highlighted
Dual Super User
Dual Super User

Re: When an item is modified on a specific column send an email with certain info

Hi

triggerBody()?['Tekniker som sover']

is probably wrong since spaces in column Names are stored internally in Sharepoint with a different value.

If you hover the mouse over the "column name icon" once you add it from the dynamic content menu, you will see its internal name.

Please also note if this SP column is configured to assign multiple values, then its output is an array, so maybe this explains the Apply to Each automatically added by the editor.

Hope this helps



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



Highlighted
Helper V
Helper V

Re: When an item is modified on a specific column send an email with certain info

Hello!

 

And thanks for your reply, but i'm stuck..

 

Maybe you can help me some more?

 

So I got it to work kinda good, but I would like to get rid of the "Apply to each" because everytime I make an update in that object people will get several mails at once because it triggers 4 times = 4 people in the object.

 

I would like it to only send one email with only the column I updated, is that possible?

Highlighted
Dual Super User
Dual Super User

Re: When an item is modified on a specific column send an email with certain info

Hi again

Let me see if I understood your requirements... So assuming this column is type person group allowing multivalues, and the SP item from your example has 4 people assigned in this column, you requirement is to send a single email to a supervisor, with the names of these 4 people, right?

If so, you will probably need to add an 'Initialize variable' of type string just before the Apply to Each, keep the apply to each, replace this column dynamic content from 'Send an Email' and add the new variable instead; and move this block after (outside) the Apply to Each.

Once done, you nedd to add inside the Apply to Each a 'Append to string variable' action block, and use as input the column dynamic content

 

Hope this helps



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



Highlighted
Community Support
Community Support

Re: When an item is modified on a specific column send an email with certain info

 

Hi @288088 ,

 

If you want to send a single email to all people in this person filed and check if this field is empty, you could refer to the following method.

  • Initial a string variable to collect all email addresses in the person field.
  • Use length() function to check if the person field is empty.
  • Append all email addresses in string variable through Append to string variable action, separated by a semicolon.

Image reference:

44.PNG45.PNG

Hope this helps.

 

Best Regards,

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

Re: When an item is modified on a specific column send an email with certain info

Thanks for the reply

 

But that isnt exacly what i'm looking for.

 

I will try to be more clear in my explaination, sorry for my bad english 🙂

 

I've been thinking this through and its not exacly how i've been explaining it before.

 

When an item is created or modified I dont want an email to go away direcly, I want it to wait untill 07:00 in the morning and then send an email how the item looks like 07:00.

 

1. When an item if created or modified (Only TODAY not back in time)

2. Check these conditions: (Both these have to be true, or else false and no mail will be sent):

- Check if there is a value in column "Tekniker som sover". (Can be several people in this)

AND

- Check if column "Agreement area" has the value "UH1".

3. IF yes

4. wait until 07:00 in the morning

5. "Send an Email" (just one email) with all the information (to certain people I will specify)

 

In that email I want the People in column "Tekniker som sover" to be like this if its possible:

1. Name surname

2. Name surname

3. Name Surname

 

Thanks!

Highlighted
Dual Super User
Dual Super User

Re: When an item is modified on a specific column send an email with certain info

Hi
My suggestion is to add either a 'Delay' or a 'Delay until' action block just after the trigger.
You will probably have to get current date and time with utcNow() function before, and do some calculations. Once Delay block ends, start executing the rest of the stuff discussed so far
Hope this helps
Hope this helps


Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



Highlighted
Community Support
Community Support

Re: When an item is modified on a specific column send an email with certain info

 

Hi @288088 ,

 

Regarding when to send an email notification and what conditions need to be met, please apply @efialttes ’s suggestions to adapt your Flow.

Besides, if you want to the body can be formatted like you mentioned, please refer to the following method:

58.PNG59.PNG60.PNG

You could customize the format of the body using HTML tag.

 

Best Regards,

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

Helpful resources

Announcements
firstImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

firstImage

Join the new Power Virtual Agents Community!

We are excited to announce the launch of Power Virtual Agents Community. Check it out now!

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

Top Solution Authors
Top Kudoed Authors
Users online (7,034)