cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
MrEdward
Helper II
Helper II

Gallery inside of Component with SharePoint list connected

Hi,

 

I'm trying to figure out how to build a Component with a Gallery inside that is connected to a SharePoint list (EdwardTestList).

I get errors when I try, but when I connect the gallery to collections, it works fine. Anyone have any idea?

error.png

 

Any help is appreciated, thanks! 

1 ACCEPTED SOLUTION

Accepted Solutions
EricLott
Resident Rockstar
Resident Rockstar

You'll want to set up an input property in your component that accepts the collection once it's in use in your app. The component itself doesn't need to reference the collection, since that would make it less modular (the idea behind components is that they can be used across different screens as well as apps). You'll then use this input property as the reference for the collection.

2020-02-19 16_52_56-InternalApps - Microsoft Visual Studio.png

I'd like to add that there is currently a bug affecting components that Microsoft is working on. Components are not working well with global variables (Set), but they seem to be working with Collections and local (UpdateContext) variables

---
If this answered your question, please click "Accept Solution". If this helped, please Thumbs Up.

View solution in original post

3 REPLIES 3
EricLott
Resident Rockstar
Resident Rockstar

You'll want to set up an input property in your component that accepts the collection once it's in use in your app. The component itself doesn't need to reference the collection, since that would make it less modular (the idea behind components is that they can be used across different screens as well as apps). You'll then use this input property as the reference for the collection.

2020-02-19 16_52_56-InternalApps - Microsoft Visual Studio.png

I'd like to add that there is currently a bug affecting components that Microsoft is working on. Components are not working well with global variables (Set), but they seem to be working with Collections and local (UpdateContext) variables

---
If this answered your question, please click "Accept Solution". If this helped, please Thumbs Up.

Hi @MrEdward,

As of December, API connectors are the first ones that work inside components right now:

https://powerapps.microsoft.com/blog/canvas-components-get-support-for-connectors/

Thank you @Mr-Dang-MSFT , is there any documentation to it please? I've just tried and it wasn't working. Maybe I'm doing something wrong?

Helpful resources

Announcements
PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

Microsoft Build 768x460.png

Microsoft Build is May 24-26. Have you registered yet?

Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.

May UG Leader Call Carousel 768x460.png

What difference can a User Group make for you?

At the monthly call, connect with other leaders and find out how community makes your experience even better.

Top Solution Authors
Top Kudoed Authors
Users online (3,426)