cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
sdowse
Resolver I
Resolver I

Invalid number of arguments - running flow from button in a canvas app embedded in a model driven form

Hello Everyone!

 

This is a bit of a crossover between Power Apps and Power Automate! I've got a model driven app based on CDS. In one of the entities (Quote) the main form has an embedded canvas app with 4 buttons on it, each of which run separate flows. I've got the first two buttons and flows working, and I've now got the third flow working (with lots of help from you!), but I'm getting an error when creating the flow.run expression for the button On Select - it says it's expecting 0 parameters - but my flow asks the app for details of the Quote record (see screenshot of the flow) - so, like with the other two buttons, which also ask the app for details of the Quote record (and are working) - I'm putting the expression shown in the screenshot below.

 

To be able to clear the error (also shown in the screenshot) I have to put OnHoldbuttonflow.Run() - this starts the flow going but, not surprisingly, the flow fails to run as it is not being sent details of the Quote record by the app - see last screenshot for the flow error.

 

Has anyone come across this issue before?

 

Thanks!

 

Simon

 

Capture5.PNGCapture6.PNGCapture7.PNG

 

1 ACCEPTED SOLUTION

Accepted Solutions
sdowse
Resolver I
Resolver I

I've solved it!

 

The Item Identifier in the Get Quote record action as shown in the screenshot in my original post was wrong - I don't know why it was wrong, as I selected the "Get from powerapps" dynamic content when I created it. 

 

It should be as below - the On Select flowRun now wants a parameter. I got this by deleting the existing purple box (sorry, I don't know what its called!) and reselected the "Get from powerapps" dynamic content.

 

So it was originally triggerBody()['Getrecord_Itemidentifier'] - which didn't work

It is now triggerBody()['GetQuoterecord_Itemidentifier'] - which does work

 

 

Capture8.PNG

View solution in original post

2 REPLIES 2
sdowse
Resolver I
Resolver I

I've solved it!

 

The Item Identifier in the Get Quote record action as shown in the screenshot in my original post was wrong - I don't know why it was wrong, as I selected the "Get from powerapps" dynamic content when I created it. 

 

It should be as below - the On Select flowRun now wants a parameter. I got this by deleting the existing purple box (sorry, I don't know what its called!) and reselected the "Get from powerapps" dynamic content.

 

So it was originally triggerBody()['Getrecord_Itemidentifier'] - which didn't work

It is now triggerBody()['GetQuoterecord_Itemidentifier'] - which does work

 

 

Capture8.PNG

View solution in original post

rohsh354
Microsoft
Microsoft

Hello,

 

That's good to know. Thanks for sharing the scenario and the solution. I am sure it can help other community users.

 

 

Helpful resources

Announcements
User Groups Public Preview

Join us for our User Group Public Preview!

Power Automate User Groups are coming! Make sure you’re among the first to know when user groups go live for public preview.

New Super Users

Meet the Power Automate Super Users!

Many congratulations to the Season 1 2021 Flownaut Crew!

Power Platform ISV STudio

Power Platform ISV Studio

ISV Studio is the go-to Power Platform destination for ISV’s to monitor & manage applications post-AppSource publish.

Users online (40,358)