In this Power Apps Tutorial, We will discuss how to create collection from SharePoint list PowerApps.
You can also read another article on How to create PowerApps collection from Excel.
To create PowerApps Collections from SharePoint List, We need to follow these below processes as:
- Create a SharePoint List and Add some items into that List
- Create a Canvas app in Power Apps
- Connect a new or existing Data Source and SharePoint Site to your App
- Add a Button and Apply the List Collections Formula
- Preview the Canvas app in the Power Apps
- SharePoint List Items added into the Power Apps Collections
Below is the syntax to to Create Collection from SharePoint List in PowerApps.
- Collect = Collection Function Name which is used to create Powerapps Collections
- MyListCollection = Collection Name
- ListName = Provide the SharePoint List Name which contains the items that you wants to display in the Powerapps Collections
Create a SharePoint List and Add some items into List
First of all, In the SharePoint Site, I have created a List named “Hospital Registration Details“. This list has some columns and records of some patients as shown below.
Create a Canvas app in Power Apps
- Sign in the PowerApps app with your credentials.
- Go to Apps option from the left navigation.
- Select Canvas under the + New app tab from the top of the page.
- Select Tablet layout under the Blank app section as like below screenshot.
Click on to connect to data from the middle of the page and expand the Connectors (from left navigation). Select the new Data Source as SharePoint as shown below.
Also, you can directly search the SharePoint in the Search bar.
Provide your SharePoint Site URL for the location of your list and hit the Connect button. Also, you can directly search the SharePoint Site Url under the Resent sites section.
Choose your SharePoint List (Hospital Registration Details) and click on the Connect button.
Add a Button and Apply the List Collection Formula
Now in the Power apps Screen, add a Button (Click Insert -> Button).
Just rename the Button name to Add SharePoint List Item to Collection by double clicking on it. Also, you can provide some button properties like Font size, Font color, Border etc.
Those above properties you can change under the Button Properties section (From the right side of the page).
Select the Button and apply the below formula in its OnSelect Property to this function.
OnSelect = Collect(ListCollection,'Hospital Registration Details')
- OnSelect = Button Property Name
- Collect = Collection Function Name
- ListCollection = Collection Name
- Hospital Registration Details = SharePoint List Name
Preview the App in the Power Apps
Now preview the app to see how it works. To preview, click on F5 or Preview icon from right top of the page.
In the Preview screen, the Button will appear as the below screenshot. Just hit on this button. There will be no effect when you will hit the button, but all the list items will be added into the Collections.
To view all the SharePoint List Items in the Powerapps Collections, Go to View tab -> Collections as shown below.
Click on your Collection Name (ListCollection) and then you can view the first 5 items in the collection.
In the below screenshot, some of the boxes are appearing in the Collections. When you will click on it, then you can see the details.
Also, you may like some below Powerapps Tutorials:
- PowerApps Collection: Add, Update, Remove and Filter items
- How to display images from a SharePoint Online library in PowerApps
- Create PowerApps App for SharePoint List
- How to share PowerApps with external users
- PowerApps Functions Tutorial
- How to create and use PowerApps Collection
- PowerApps Media Control
- PowerApps submit form to SharePoint Online list
- Display SharePoint Online List Columns in multiple screens in Microsoft PowerApps
In this Power Apps Tutorial, We discussed how we can create collection from sharepoint list PowerApps.
I am Bijay from Odisha, India. Currently working in my own venture TSInfo Technologies in Bangalore, India. I am Microsoft Office Servers and Services (SharePoint) MVP (5 times). I works in SharePoint 2016/2013/2010, SharePoint Online Office 365 etc. Check out My MVP Profile.. I also run popular SharePoint web site EnjoySharePoint.com