web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Selecting Gallery info...
Power Apps
Unanswered

Selecting Gallery info containing containers

(0) ShareShare
ReportReport
Posted on by 438

I have an issue where I have created a gallery where I have a horizontal container showcasing the information as different labels. 

The OnSelect property of each label is EditForm(Form1) then I have my form which has the Item property set to Gallery1.Selected.

 

I am getting an error. Gallery Selected issue.jpg

 

If I create a gallery without the containers and this works fine. What am I missing ??

 

Categories:
I have the same question (1)
  • AhmedSalih Profile Picture
    6,678 Moderator on at
    Re: Selecting Gallery info containing containers

    Hello, @nshaw75, the Datasource schema that you are using in the Items property of the Gallery has to be the same schema that you are using in the DataSource property of the Form control.

     


     

    If my reply helped you, please give a 👍 If it solved your issue, please give a 👍 & accept it as the Solution to help other community members find it more.

    Visit my Blog: ahmedsalih.blog

    Visit my YouTube Channel: https://www.youtube.com/@powerplatformplace/videos

     

     

  • Verified answer
    WarrenBelz Profile Picture
    152,845 Most Valuable Professional on at
    Re: Selecting Gallery info containing containers

    Hi @nshaw75 ,

    An alternative structure here that will address this and also have many other benefits
    OnSelect of your Gallery

    Set(
     gblRecord,
     LookUp(
     SPListName,
     ID = ThisItem.ID
     )
    )

    This allows for your gallery to have removed/added fields to your list.

    Item of your Form

    LookUp(
     SPList,
     ID = gblRecord.ID
    )

    OnSuccess of your Form

    Set(
     gblRecord,
     Self.LastSubmit
    )

    Apart from solving your current issue, you will find that any controls based directly on the SP List will refresh automatically and you can refer to any field in the current record with simply

    gblRecord.YourFieldName

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

    MVP (Business Applications)   Visit my blog Practical Power Apps

     

  • nshaw75 Profile Picture
    438 on at
    Re: Selecting Gallery info containing containers

    Thanks Warren, I have been playing around with it today and finally seem to be getting somewhere. I just don't understand why it has been working in all my other apps, yet on this one it doesn't seem to want to follow suit 

  • WarrenBelz Profile Picture
    152,845 Most Valuable Professional on at
    Re: Selecting Gallery info containing containers

    Hi @nshaw75 ,

    You will find that taking a bit of time for a small amount of code to make specific references will do a lot to “future proof” your app.

  • nshaw75 Profile Picture
    438 on at
    Re: Selecting Gallery info containing containers

    Many thanks, I am going to pick this up again this morning to see how it all fits in nad hopefully can get the entire app running. I am trying to set up a standard template so fingers crossed if I can nail it on this one all the future ones will be the same. 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 757 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 322 Super User 2025 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 209 Super User 2025 Season 2

Last 30 days Overall leaderboard