cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
AmayKulkarni
Level: Powered On

Re: Flow: Existing item is modified triggers when a new item is created in Sharepoint list

yes, i am also facing same issue, created and modified are different in Item create, how to handle it?

wnzn
Level 8

Re: Flow: Existing item is modified triggers when a new item is created in Sharepoint list

Take a look at this blog post. Using this API call does not trigger another instance of the same Flow.

 

https://robertschouten.com/2018/04/30/update-file-metadata-with-rest-api-using-validateupdatelistite...

MariaOrza
Level: Powered On

Re: Flow: Existing item is modified triggers when a new item is created in Sharepoint list

@wnzn There is one trigger called : When an existing item is modified  in this Flow Template . Maybe the use got it from there. 

when an existing list item is modified.PNG

when an existing list item is modified1.PNG

DanielaHo
Level: Powered On

Re: Flow: Existing item is modified triggers when a new item is created in Sharepoint list

Hi Kris, 

 

I have tried your solution but when I enter 

@equals(triggerBody()?['Created'], triggerBody()?['Modified'])

I get an error saying "The expression is invalid". Has anything changed since your post?

 

Capture2.JPG

wnzn
Level 8

Re: Flow: Existing item is modified triggers when a new item is created in Sharepoint list

You need to add one part of the condition (created) in the left input box and the other part (modified) in the right input box. 🙂 

marsin04
Level: Powered On

Re: Flow: Existing item is modified triggers when a new item is created in Sharepoint list

FOUND HIDDEN ON MODIFY TRIGGER ACTION - I was also having trouble due to the Created & Modified times being 1 minute apart from one another (even when it truly was a new Item), so I found a Template that claims it Triggers solely on a Modified Existing Item. Use this Template and then change out the subsequent actions (after the Trigger action) to what you need!Flow Template - trigger on Modify.PNG

On modify.png

User21453123
Level: Powered On

Re: Flow: Existing item is modified triggers when a new item is created in Sharepoint list

Still not working. Any suggestions? my flow is constantly looping endlessly. Is there an option to stay execute once and stop afterwards?

wnzn
Level 8

Re: Flow: Existing item is modified triggers when a new item is created in Sharepoint list

No, as every instance of your Flow is unaware of other runs.

 

As I suggested, you can update your current item by calling the SharePoint REST API and using the ValidateUpdateListITem() method.

 

X.png

 

The body of your call should look like this:

{
	"formValues": 
	[
		{"FieldName": "FileLeafRef", "FieldValue": "Rename.docx"},
		{"FieldName": "Title", "FieldValue": "New Title"}
	],
	"bNewDocumentUpdate": true
}

Where you add each field you want to update in the formValues object.

 

By setting the bNewDocumentUpdate to true, you say to SharePoint that this is a "system update" so there is no new version created and the Flow is not triggered again.

 

You can find more information about supported fields at the bottom of this post: http://blog.arvosys.com/2018/07/06/list-items-system-update-options-in-sharepoint-online/index.html

 

CRISLIPSKI
Level: Powered On

Re: Flow: Existing item is modified triggers when a new item is created in Sharepoint list

I LOVE YOU!!! Works perfectly!

DanielaHo
Level: Powered On

Re: Flow: Existing item is modified triggers when a new item is created in Sharepoint list

Hi All, 

I am finding that a Flow triggered 'when item is created or modified' takes several minutes to be triggered when the item was modified... whereas the Flow triggers very quickly when a new item was created. Anyone else finding the same thing?

Helpful resources

Announcements
firstImage

Better Together Contest Finalists Announced!

Congrats to the finalists of our ‘Better Together’-themed T-shirt design contest! Click for the top entries.

firstImage

Incoming: New and improved badges!

Look out for new contribution recognition badges coming SOON!

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!

sixthImage

Community Summit North America

The top training and networking event across the globe for Microsoft Business Applications

Top Solution Authors
Users online (4,855)