cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Ben-Skipper
Helper I
Helper I

apply to each flow issue

Hi,

 

I am trying to put together an approval flow using more than one approval but I am getting the below error message. 

BenSkipper_0-1656673246987.png

 

The apply to each on the left hand side auto populates when selecting a response in the update item.

 

Any help would be much appreciated.

 

Thank you. 

 

Kind regards,

Ben

 

1 ACCEPTED SOLUTION

Accepted Solutions
Shuvam-rpa
Solution Supplier
Solution Supplier

@Ben-Skipper your expression is not correct, please check below expression

 

outputs('Start_and_wait_for_an_approval_2')?['body/responses'][0]?['approverResponse']
 
you put space in 'Start and wait.... ' which was not correct.
 
Request you  to make it same like my expression.
 
 
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

10 REPLIES 10
MarconettiMarco
Super User
Super User

Hello @Ben-Skipper ,

that's correct, it's not an error. Which option have you selected in the "Approval type"?

MarconettiMarco_1-1656674090530.png

 

If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

 

BR,

Marco

 

Shuvam-rpa
Solution Supplier
Solution Supplier

@Ben-Skipper what dynamic value you are trying to update from left side approval in update item action

Hi Maronetti,

 

Thank you for your response. 

 

The approval type is 

BenSkipper_0-1656675883738.png

 

KR,

Ben

ok @Ben-Skipper ,

that's correct, if in the next steps you're adding values got from the "Start and wait for an approval" action, the flow will automatically add the Apply to each loop. This is happening also if you select the "First to respond" Approval type.

 

If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

 

BR,

Marco

Hi Shuvam,

 

Thank you for your response. 

 

The dynamic value I am updating is the approvers response from the approval. 

BenSkipper_1-1656676297297.png


This is what populates the apply to each.

 

KR,

Ben

 

 

Shuvam-rpa
Solution Supplier
Solution Supplier

@Ben-Skipper there is no need of apply to each loop. same thing can be achieve using below expression

 

outputs('Start_and_wait_for_an_approval_2')?['body/responses'][0]?['approverResponse']
 
request you to delete the apply to each loop first and then create update item action and then put the expression on the field you need to update.
 
 
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!

Hi Shuvam, 

 

Thank you again. The expression has worked but now I get another error. Please see below.

BenSkipper_0-1656683929726.png

 

Do you know how I can fix this please?

KR,

Ben

Shuvam-rpa
Solution Supplier
Solution Supplier

@Ben-Skipper please send me the screenshot of the expression in edit mode.

and output of the action failed.

BenSkipper_0-1656686377818.png

BenSkipper_1-1656686410023.png

 

BenSkipper_2-1656686432829.png

 

@Shuvam-rpa please see the expression in edit mode.  believe it works otherwise it would not populate in the box.

 

KR,
Ben

Shuvam-rpa
Solution Supplier
Solution Supplier

@Ben-Skipper your expression is not correct, please check below expression

 

outputs('Start_and_wait_for_an_approval_2')?['body/responses'][0]?['approverResponse']
 
you put space in 'Start and wait.... ' which was not correct.
 
Request you  to make it same like my expression.
 
 
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!

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

New Ideas Forum MPA.jpg

A new place to submit your Ideas for Power Automate

Announcing a new way to share your feedback with the Power Automate Team.

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

MPA Licensing.jpg

Ask your licensing questions at the Power Automate AMA!

Join Priya Kodukula and the licensing team, super users and MVPs to find answers to your questions on Power Automate licensing.

Super User 2 - 2022 Congratulations 768x460.png

Welcome Super Users

The Super User program for 2022- Season 2 has kicked off!

Users online (5,502)