With Shane’s super simplified solution, learn how to create a button that uploads a file directly to your SharePoint document library from Power Apps. Includes PDFs, word docs, excel files, images and more.
In this video, you will learn about:
The Attachment control
The Image control
The Set function
The JSON function
base64ToBinary flow formula
The EasyUpload.Run action
Link to the video on YouTube: Power Apps upload file to SharePoint document library
Link to the video and the app download for Curated Library subscribers: Upload a file to SharePoint Document Library
Key Timestamps:
0:00 Intro
1:54 Demo of the solution
Shane demonstrates the functionality of his ‘Upload a file to a SharePoint Document Library’ app. The button displays all files, rather than a select group of files.
3:51 Create the solution in Power Apps and add the Attachment and Image controls
An Attachment control is added to the app and gives users the ability to access all files. An Image control is added to the app and the Last function is used to display the image that has been selected by the user.
6:20 Add a button to the app and utilize the Set and JSON functions
A button is added to the app. The Set and JSON functions are added to the button in order to upload a file directly to a SharePoint document library.
9:16 Perform text manipulation to isolate the base64
The Mid, Find, and Len functions are added to the button to isolate the base64.
13:53 Write a flow to get the base64 into SharePoint
A base64ToBinary expression is written to reencode the strings.
18:05 Perform additional text manipulation
The EasyUpload.Run action is added to the button.
20:07 Demo of the final solution
Shane demonstrates the functionality of the final solution by uploading a PDF from the app to the SharePoint document library. He then verifies that the varFileLink has a valid URL.
21:25 Simplify the appearance of the app
The code is rearranged and the only remaining visible item on the app is the Attachment control.
Additional learning:
Video: Power Apps Flow Intro Upload an image to SharePoint using Flow
Video: Power Apps upload a file to SharePoint and set the metadata
Do you want to become a Power Apps Rockstar? Check out our different full length training classes at https://training.PowerApps911.com or you can download a working version of the app we built today by subscribing to the Curated Library.
Great video Shane!