Dec 12 2022 03:01 AM
Hi,
I have a rule setup for my list, where if a particular column (Status) is set to a particular answer (Accepted), then an email is triggered and sent to the original requestor.
I want to be able to edit the content of this email, is that possible? Essentially when a request is accepted, I want the requestor to receive the email notification but for it to include a link to a form.
I don't see anywhere to edit the content of this email/notification that's triggered?
Dec 15 2022 03:14 AM
Solution@goulp99 You can't change anything in an alert. You would need to do this Power Automate. First of all make sure that versiong is switched on in your list settings because we will be comparing the current value of the status column with the previous one.
The flow looks like this:
1. The trigger is the SharePoint "when an item or a file is modified":
2. The first action is "get changes for an item or a file (properties only)" and in the Since field you need to add the following expression to get the previous version:
sub(int(triggerOutputs()?['body/{VersionNumber}']),1)
3. You then add a condition to check if it's the Status column that has changed and if the status is now Accepted
In the green if yes channel add your send an email action. If you are adding links into it cluick the code view button </> and use html tags.
The email can display whichever columns from your list that you want. But you can't change the text of the email on the fly; if the wording was different but standard based on one particular column then you'd need to add a switch action in it (a type of condition) to check that column and in each "case" send the appropriate email.
Rob
Los Gallardos
Microsoft Power Automate Community Super User
Dec 21 2022 02:07 AM
Firstly, thank you Rob! This was really easy to follow and very helpful, I appreciate the detailed response.
I've followed the steps above in automate and have created the flow. I've tested it, both manually and automatically, it comes back as successful for both but I don't receive the email notification. For the email I have configured it to send to "Requestor Email", for testing I am the requestor.
Please see screenshots below:
Searching for myself, in the list, as the requestor:
Configured to send email to: "Requestor Email"
After testing the flow and changing the status to accepted, as per the defined conditions in this flow, it say's completed successfully, but get the below message:
Dec 15 2022 03:14 AM
Solution@goulp99 You can't change anything in an alert. You would need to do this Power Automate. First of all make sure that versiong is switched on in your list settings because we will be comparing the current value of the status column with the previous one.
The flow looks like this:
1. The trigger is the SharePoint "when an item or a file is modified":
2. The first action is "get changes for an item or a file (properties only)" and in the Since field you need to add the following expression to get the previous version:
sub(int(triggerOutputs()?['body/{VersionNumber}']),1)
3. You then add a condition to check if it's the Status column that has changed and if the status is now Accepted
In the green if yes channel add your send an email action. If you are adding links into it cluick the code view button </> and use html tags.
The email can display whichever columns from your list that you want. But you can't change the text of the email on the fly; if the wording was different but standard based on one particular column then you'd need to add a switch action in it (a type of condition) to check that column and in each "case" send the appropriate email.
Rob
Los Gallardos
Microsoft Power Automate Community Super User