cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Frank89
Helper I
Helper I

Get list changes in email

Hi everybody, 

 

I am new here and hope to get some support. 

I want to create a flow which is sending an email with all changes been made in a SPO list. For example an items (ID: 34) status (changed to "waiting") and priority (changed to "high") was changed, I want the flow to create an email with the details that have been changed. 

 

The content of the email should be 

ITEM ID: 34

Changes:

status has been changed to: "waiting"

priority has been changed to: "high"

 

Here is the setup of my flow so far.
1. Trigger: When an item or a file is modified
2. Action: Get changes for an item or a file (properties only)
3. Condition: Has Column Changed = true
4. If true = send email with list details that have change.

 

1. Trigger: When an item or a file is modified  2. Action: Get changes for an item or a file (properties only)1. Trigger: When an item or a file is modified 2. Action: Get changes for an item or a file (properties only)Flow02.jpg

 

1 ACCEPTED SOLUTION

Accepted Solutions
yashkamdar
Solution Sage
Solution Sage

Hello Team,

 

You are already close to your solution, just that you committed a simple mistake in the Condition.

 

Here is the detailed flow that will help you out achieve the solution-

 

Step 1 and 2 - 

 

yashkamdar_0-1600785101577.png

 

 

Step 3 - COMPOSE action

 

Create a compose action and populate it with the value that you want to check if it was modified or not. In my case I check if my Attendees column was modified or not so I populate the compose with Attendees.

 

 

yashkamdar_1-1600785126501.png

 

 

Step 4 - Condition ---> Most important

 

yashkamdar_3-1600785240935.png

 

 

yashkamdar_2-1600785190266.png

 

 

Step 5 - Send an email 

 

yashkamdar_4-1600785336899.png

 

 

 

Final output looks like this -

 

yashkamdar_5-1600785368447.png

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

 

 

View solution in original post

5 REPLIES 5
yashkamdar
Solution Sage
Solution Sage

Hello Team,

 

You are already close to your solution, just that you committed a simple mistake in the Condition.

 

Here is the detailed flow that will help you out achieve the solution-

 

Step 1 and 2 - 

 

yashkamdar_0-1600785101577.png

 

 

Step 3 - COMPOSE action

 

Create a compose action and populate it with the value that you want to check if it was modified or not. In my case I check if my Attendees column was modified or not so I populate the compose with Attendees.

 

 

yashkamdar_1-1600785126501.png

 

 

Step 4 - Condition ---> Most important

 

yashkamdar_3-1600785240935.png

 

 

yashkamdar_2-1600785190266.png

 

 

Step 5 - Send an email 

 

yashkamdar_4-1600785336899.png

 

 

 

Final output looks like this -

 

yashkamdar_5-1600785368447.png

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

 

 

View solution in original post

Hello yashkamdar, 

thanks for your response. 

I need to fill in something before send an email (apply to all). --> Column has changed: status is not working here. 

 

"ExpressionEvaluationFailed. Fehler beim Ausführen der Vorlagenaktion "Auf_alle_anwenden". Das Ergebnis der Auswertung des foreach-Ausdrucks "@outputs('Änderungen_für_ein_Element_oder_eine_Datei_abrufen_(nur_Eigenschaften)')?['body/ColumnHasChanged/Status']" weist den Typ "Boolean" auf. Das Ergebnis muss ein gültiges Array sein." 

 

Any idea whats wrong? 

 

Thanks!

Hello Team,

 

Can you show me what you are trying to fill in with some detailed screenshot.


Let me know. Awaiting response...

Through the "Has Column Changed" I would like to show all changes at once. Or is this not possible and do I have to make a flow for every Column that might change? 

Flow03.jpgFlow04.jpg

I see a post is marked as a solution here, but I cant see how it answers your question.

I found this post, looking for a way to use the "column has changed" in apply to each, and only get the values for the changed columns. If this is possible, please chime in :).

 

In the meantime, I've solved it like this:

 

  • Initialize a string variable, to store the text/html for the updated columns
  • Build a condition for every column you want updates on. If field is changed (true), use the value from trigger and append to your string variable. Repeat for all the columns you want to check.
  • Add a condition that checks length(yourstringvariable) is greater than zero. Terminate the flow if there is no updates.
  • If you have any updates, use your string variable in whatever message action you want to use.
 

Here is a simple test:

Capture.JPG

 

Helpful resources

Announcements
MPA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

V3_PVA CAmpaign Carousel.png

Community Challenge - Giveaways!

Participate in the Power Virtual Agents Community Challenge

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

R2 (Green) 768 x 460px.png

Microsoft Dynamics 365 & Power Platform User Professionals

DynamicsCon is a FREE, 4 half-day virtual learning experience for 11,000+ Microsoft Business Application users and professionals.

Top Solution Authors
Users online (2,509)