web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Error Updating Sharepo...
Power Automate
Unanswered

Error Updating Sharepoint List Item

(0) ShareShare
ReportReport
Posted on by

Hello everyone,

 

I have a problem with the action "Update item", when updating an item in a Sharepoint list. The sharepoint list is used to record document approval flows (Start and wait for an approval).

 

To create the item in the sharepoint list I use the create elements action, but in the fields of the list I use information from the action Start and wait for an approval, and that causes me to change to “Apply to each one”. (IMAGE “Error 1”)

 

When I call "Update item" in the second approver of the document, it throws an error because I cannot extract the ID of the item that I created in the sharepoint list with "Create item" to include it in the identifier field, because I think it is not a valid dynamic content.

 

This is the error message: Template validation failed: "The entries for the template action "Update_element" in line "1" and columna "25053" are invalid. Action "Apply_to_each_one_41" must be a scope "for each" primary of the "Update_element" action so that the "repeatItems" or "items" functions refer to it.". (Image 2)

 

Please can you help me to know how can I solve this error or how can I update the item in the sharepoint list without the action becoming “Apply for each one”. (IMAGE “Error 2”).

 

Thank you!!!

 

Image Error 1Image Error 1Image error 2Image error 2

Categories:
I have the same question (0)
  • nitika Profile Picture
    on at

    Hi @Carlosherrerad 

    Could you explain your complete requirement from the flow which you have designed? Also, it'll be of great help if you could send the screenshots in English.

     

    Thanks

     

  • Community Power Platform Member Profile Picture
    on at

    Hello @nitika ,

     

    I am developing a workflow for a document (Procedure, Manual, etc.) to be approved by several people. The flow was triggered manually when I select the document in a Sharepoint library. Image 1 Trigger Flow.

     

    For approvals I use the "Star and wait for an approval" action, which triggers a mail flow where the person can approve or reject. Image 2 Star and wait for an approval.

     

    The traceability of the approval flow I am taking through a Sharepoint list (I tried to create and configure the fields in the library and I could not, almost damaged the entire sharepoint site), and for this I use the “create item” action (Image 3 Create Item), with the Next information:

     

    Name - File Name

    User name - The display name of the user who triggered the flow

    Responses Approver name - The name of the approver

    Responses comments - Comments added by the approver

    Outcome - The outcome of the approval

    Completation Date - Date the approval was complete

     

    When the item is created, an ID is automatically generated for the item in the sharepoint list, and that ID is what I want to use to update the item.

     

    The flow continues into the next stage, which is reviewing the document by a second approver, and this is where I have the problem. When I use the action "Update item" (Image 4 Update item) in the second approver of the document, it throws the following error:

    The inputs of template action "Update item" at line '1 and column 26811' is invalid. Action 'Apply_to_each' must be a parent 'foreach' scope of action 'Update item' to be referenced by 'repeatItems'or 'items' functions. Image 5 Update item error.

     

    It is at this stage where the error is being presented, because I cannot get the ID of the item from the sharepoint list to update it. I think it may be because the action "Create item" is framed in another one that is "Apply to each", but I have not been able to find a way to extract that ID (Maybe it can be done with a formula) and include it in update item action.

     

     

     

    Image 1 Trigger FlowImage 1 Trigger FlowImage 2 Star and wait for an approvalImage 2 Star and wait for an approvalImage 3 Create ItemImage 3 Create ItemImage 4 Update ItemImage 4 Update ItemImage 5 Update Item errorImage 5 Update Item error

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 501 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 323 Moderator

#3
abm abm Profile Picture

abm abm 237 Most Valuable Professional

Last 30 days Overall leaderboard