What actually happen when we set DisableAppViews & DisableFlows to true using PnP

john john 946 Reputation points
2021-03-05T21:19:57.223+00:00

Most of the time when I create a new modern sites, I set DisableAppViews & DisableFlows to true, to hide the MSFlow and PowerApp buttons inside the modern UI from the end users as follow:-

 Connect-PnPOnline –Url https://***.sharepoint.com/sites/POS-DocumentApprovalProcess/ –Credentials (Get-Credential)
 $ctx = Get-PnPContext
 $ctx.Site.DisableAppViews = $true;
 $ctx.ExecuteQuery();
 $ctx.Site.DisableFlows = $true;
 $ctx.ExecuteQuery();

but even if i disable the MSFlows and AppViews, i am still able to create a MSFlow from the MS Flow app and link it to a SharePoint list + i can login to power app and create a new power app and link it to SharePoint + using the site owner i can customize the list forms using power app.. so can i conclude that the above PnP will only hide the PowerApp & MSFlow from the UI, but will not prevent us from creating MS Flow and Power App for the site?

SharePoint
SharePoint
A group of Microsoft Products and technologies used for sharing and managing content, knowledge, and applications.
9,684 questions
{count} votes

2 answers

Sort by: Most helpful
  1. Trevor Seward 11,681 Reputation points
    2021-03-06T18:56:53.8+00:00

    These SharePoint Online settings simply hide the UI elements to access those Power platform features. They do not prevent a user from starting a task from the Power platform and connecting back to the sites.

    This is by design behavior.

    0 comments No comments

  2. Echo Du_MSFT 17,116 Reputation points
    2021-03-08T02:23:05.503+00:00

    Hi @john john ,

    Indeed. Running this PowerShell command just hides Flow Button and PowerApps Button, but does not disable Flow and PowerApps. Therefore, you can still start Flow and PowerApps interface.

    If you want to change again to show the buttons, set the properties DisableAppViews and DisableFlows to $false.

    Thanks,
    Echo Du

    ===================

    If an Answer is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments