I have a Power Automate which is meant to be triggered by clicking a button in my app. I keep getting an error however which is stopping it from working as it appears to not be able to pick up the 'ThisItem.ID'
The weirdest bit is that I have a previous version on which it was working fine. I can't use this previous version as the live as there have been other fixes made elsewhere in the app which will be a huge pain to have to do again, so I'm just trying to add this icon to the live version now when I get this error.
Screenshot below of the working one on a previous unpublished version of the app so you can see that there is no difference between the two, except that I renamed the automate flow between the two.
Appreciate any help you might be able to give!
Solved! Go to Solution.
Thanks for sharing more details. The issue here is even though you are passing a value from the app but there is no parameter created on the flow. You need to follow below steps.
1) Open the flow and remove the dynamic content from the Get Item Action. Select "Ask in PowerApps" in the dynamic content.
2) Save your flow and remove it from the app.
3) Add the flow again, this time it should accept one parameter, it is still not accepting then you need to repeat step 1-2.
4) Once it is having a parameter, then you can pass FlowName.Run(ThisItem.ID)
Hope this Helps!
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!
It is behaving as though the flow to which you connect needs no arguments. Two things to try:
Thanks for coming back to me. I've checked my flow and it definitely only needs one (Get Item). I imagine if that was the issue then the previous version wouldn't work either but it does (I can restore to that version and still get it to run and succeed, if I revert to the 'live' version straight after I get this error again).
I have tried renaming the flow, removing it from the data connections, reconnecting it and still no luck.
That's starting to sound like a Microsoft Support Ticket kind of problem
Hi @misc
At times, it is possible when you save the flow and create an input parameter, it creates a reference but is not saved in the flow anywhere. To fix this, you can update the expression as:
FlowName.Run(ThisItem.ID, "")
Adding an empty input resolves the issue and since the second input is not used anywhere, it just bypasses it.
Note: Please make sure that you are keeping the order right, if you are using parameter 2, then the expression will be FlowName.Run("",ThisItem.ID)
Hope this Helps!
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!
Hope this Helps!
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!
I just tried that and it changes the error to: 'Invalid number of arguments: received 2, expected 0'
I have input a support ticket as @BCLS776 suggested so hopefully they will be able to come back to me with a solution.
If it is saying expected 0, then there is no need to pass anything. The expression will be FlowName.Run()
Hope this Helps!
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!
I did try that - and although it ran on the app side I got this error on the Flow:
Unable to process template language expressions in action 'Get_item' inputs at line '1' and column '50392': 'The template language expression 'triggerBody()['Getitem_Id']' cannot be evaluated because property 'Getitem_Id' cannot be selected.
This also doesn't explain why it works with ThisItem.ID on a previous version of the app but not the current one.
Thanks for sharing more details. The issue here is even though you are passing a value from the app but there is no parameter created on the flow. You need to follow below steps.
1) Open the flow and remove the dynamic content from the Get Item Action. Select "Ask in PowerApps" in the dynamic content.
2) Save your flow and remove it from the app.
3) Add the flow again, this time it should accept one parameter, it is still not accepting then you need to repeat step 1-2.
4) Once it is having a parameter, then you can pass FlowName.Run(ThisItem.ID)
Hope this Helps!
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!
Thank you so much! That fixed it!
The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.
This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.
User | Count |
---|---|
184 | |
53 | |
41 | |
36 | |
30 |
User | Count |
---|---|
240 | |
74 | |
71 | |
69 | |
65 |