cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
JBudinho
New Member

Gallery with multiple listboxes automatically generated from a Collection

I am trying to create a Gallery that contains multiple Listboxes from a Collection. I have a collection called Ideas, and it encompasses ideas from different participants. I am able to create a Listbox out of each participant with their ideas. However, I am trying to create a gallery that creates multiple Listboxes from that collection. It means if more participants are added to the collection, more Listboxes will automatically be created. The image shows an idea of what I am trying to achieve (See image1):

 

I tried inserting a NewGallery, then inside the galley a ListBox. On Items inside the gallery I wrote the name of the Collections, and I got multiple ListBoxes, but all of them have the same information, I got something like this (only the information from one participant is displayed in 5 ListBoxes) (See image2):

 

I could individually add the listboxes on my Screen without using a gallery, however, this would not work, because I have to add manually the information every time the collection is modified.

 

Any idea how to add multiple ListBoxes automatically from a Collection into a Gallery in PowerApps?

 

I checked the documentation in https://powerapps.microsoft.com/id-id/blog/supporting-multi-valued-listboxes-in-powerapps/ but it is not exactly what I want

Thanks in advance

 

 

 

 

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
v-xida-msft
Community Support
Community Support

Hi @JBudinho ,

Could you please share a bit more about the data structure of your collection?

Which formula do you type within the Items property of the Listbox? Do you connect the Listbox to same collection as the Gallery?

 

I assume that data structure of your Ideas collection as below:

13.JPG

On your side, you should configure your Gallery as below:

14.JPG

 

15.JPG

 

16.JPG

Set the Items property of the Gallery to following:

GroupBy(Ideas, "ParticipantColumn", "GroupData")

 

Within the Gallery, set the Items property of the ListBox to following:

ThisItem.GroupData

set the Value property in the ListBox to IdeaColumn.

 

set the Text property of the Label to following:

ThisItem.ParticipantColumn

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
v-xida-msft
Community Support
Community Support

Hi @JBudinho ,

Could you please share a bit more about the data structure of your collection?

Which formula do you type within the Items property of the Listbox? Do you connect the Listbox to same collection as the Gallery?

 

I assume that data structure of your Ideas collection as below:

13.JPG

On your side, you should configure your Gallery as below:

14.JPG

 

15.JPG

 

16.JPG

Set the Items property of the Gallery to following:

GroupBy(Ideas, "ParticipantColumn", "GroupData")

 

Within the Gallery, set the Items property of the ListBox to following:

ThisItem.GroupData

set the Value property in the ListBox to IdeaColumn.

 

set the Text property of the Label to following:

ThisItem.ParticipantColumn

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

secondImage

Demo Extravaganza is Back!

We are excited to announce that Demo Extravaganza for 2021 has started!

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

Power Apps June 2021

June Power Apps Community Call

Don't miss the call this month on June 16th - 8a PDT

Top Solution Authors
Top Kudoed Authors
Users online (73,479)