Question

I am trying to build a flow to trigger a custom email sent once a SharePoint list item is created or modified, condition is to only send it if a choice value in a certain column is set to "YES".

I add the list item, the column stays as "NO", email doesn't send. Perfect.

Couple of hours later, I modify the list item, the column still stays as "NO", email doesn't send. Perfect.

Next day, I edit the list item again, change this particular column to "YES", the email sends. Perfect.

Like I say, it's working. My issue is STOPPING the email being sent again as soon as only one email has been sent. Once the column is set to "YES", it will never be set to "NO" again.

Because I would normally go in and out of the list item at various times, I need some way of stopping the email being sent if the value was already "YES" before modifying the list item.

I tried using trigger conditions in "when an item is created or modified" setting but it triggers mail even when that particular column is not being modified but was previously set to "Yes".

Kindly suggest how can this be acheived. Thank you!

Était-ce utile?

La solution

You can overcome sending an email repeatedly by following logic :-

  1. Create a new column(you can hide it from list view) as Choice column having choices 'Yes' and 'No', say it as IsEmailSent? (Set Default value = 'No')

  2. Then in flow , check below condition before 'Send an Email' action -

If IsEmailSent == 'No' && YourChoiceColumn == 'Yes' .

  1. Add your action to 'Send an email' .

  2. Add action to update list item and set IsEmailSent= 'Yes'.

By this, email will send only once.

Licencié sous: CC-BY-SA avec attribution
Non affilié à sharepoint.stackexchange
scroll top