Introduction: In this blog, we will understand how to enable SharePoint integration in PowerApps Portal.
This blog also explains how we can create folders and add files from PowerApps Portal to SharePoint.
STEP 1: Enable SharePoint integration:
- Go to Apps.
- Select your portal –> Click on more commands(…) –> Click on Settings
- Click on “Administration“
- Go to Setup SharePoint Integration and click on “Enable SharePoint Integration“
- Click on Enable button it will then ask you to sign in again.
- Click on Accept to grant the required permissions.
- You will get the below message.
STEP 2: Enable document management for table(entity)
NOTE: If document management is not enabled already then follow below steps.
- Go to Settings –> Document Management –> Document Management Settings
- Select table
- Click on Next
- Click on OK
- Click on Finish.
STEP 3: Customizing Form
- Add Document Location subgrid in the form .(The form which you are using in the PowerApps portal)
- Save and Publish your customization.
- Create & use the different Basic(entity) forms to create and edit the record in PowerApps Portal.
- Add subgrid on forms that you are going to use to edit or view the record in PowerApps Portal.
- Don’t add a subgrid on the form which you are using to create a record in PowerApps Portal
STEP 4: Creating and Assigning Table(Entity) Permissions.
- I am enabling SharePoint Documents for the “Project” table so I have to create two table(entity) permission records one for Project and one for Document Location.
a. Table permission for the Project table. (Don’t forget to add web roles to the table permission)
b. Table permission for Document Location.
Table Name: Document Location
Scope: Parent (This will make sure the user can only see documents that are related to the record)
Parent Table Permission: Select table permission of project from lookup.
Privileges: Read,Create,Write,Append,Append To
Go to Portal, You should able to upload files now.
- Open any Project record in Portal.
- You should see the Document Section below from where you can “Add files” or Create “New folder” in SharePoint.
- Click on the “Add files” button you are shown a pop-up window from where you can choose the files to upload.
- You can see the New Folder is created in SharePoint for that Particular Project and file is also uploaded inside the respective folder.
- Click on “New Folder” to create new folder this will get created inside the parent folder in SharePoint.
- From the portal, you can go inside the folder and then upload files that get uploaded inside the respective folder in SharePoint.
- “Add Files” in newly created folder.
- New Folder and Files in SharePoint.