cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Advocate V
Advocate V

Trying to run Power Apps PowerShell for app with a space in the name - always fails

I want to disable the consent dialog on one of my apps, which is called "Receiving Pictures Upload." I've tried no quotes, single quotes, and double quotes. Same error. What am I doing wrong? I am not a PowerShell user at all, so sort of hacking my way through this.

 

PS C:\Users\userpath> Set-AdminPowerAppApisToBypassConsent -'Receiving Pictures Upload' {xxxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx}
Set-AdminPowerAppApisToBypassConsent : A positional parameter cannot be found that accepts argument '-Receiving
Pictures Upload'.
At line:1 char:1
+ Set-AdminPowerAppApisToBypassConsent -'Receiving Pictures Upload' {54 ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidArgument: (:) [Set-AdminPowerAppApisToBypassConsent], ParameterBindingException
+ FullyQualifiedErrorId : PositionalParameterNotFound,Set-AdminPowerAppApisToBypassConsent

 

1 ACCEPTED SOLUTION

Accepted Solutions

No, but it is because the syntax here is wrong, or I don't know enough about how those who talk about PowerShell write about syntax. It should be the following:

 

Set-AdminPowerAppApisToBypassConsent -AppName "xxxxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx"

 

No actual name needed, and the app ID goes in double quotes, not squiggly brackets.

View solution in original post

2 REPLIES 2
Community Support
Community Support

Hi @EdHansberry ,

 

Did you mean that if the app name doesn't contain a space, then it will run successfully?

 

Regards,

Mona

Community Support Team _ Mona Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

No, but it is because the syntax here is wrong, or I don't know enough about how those who talk about PowerShell write about syntax. It should be the following:

 

Set-AdminPowerAppApisToBypassConsent -AppName "xxxxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx"

 

No actual name needed, and the app ID goes in double quotes, not squiggly brackets.

View solution in original post

Helpful resources

Announcements
New Badges

New Solution Badges!

Check out our new profile badges recognizing authored solutions!

New Power Super Users

Congratulations!

We are excited to announce the Power Apps Super Users!

Power Apps Community Call

Power Apps Community Call: February

Did you miss the call? Check out the Power Apps Community Call here.

Top Solution Authors
Top Kudoed Authors
Users online (44,708)