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

Select(Parent) Not Working in Gallery

Hello,

 

I'm trying to build a gallery that will open up another form to edit an item but am having trouble getting Select(Parent) to work. The datasource of the gallery is a collection, and the gallery is located inside a datacard of a form. When creating an icon with the only OnSelect statement as Select(Parent) and a label with the text property set to GalleryName.Selected, the label is still blank when the icon is selected. I can't seem to get this to work. The gallery is in edit mode and the selectable property is set to true so I'm not sure what the issue is.

 

Thanks.

9 REPLIES 9
Super User III
Super User III

What you have to do is:

1. Select the EditForm and ln the Items property of the EditForm, put:
     Gallery1.Selected  (Change Gallery1 to your actual gallery name)

 

2. Dont put any formula on the icon inside the Gallery1

 

If it does not work take a screen shot

------------

If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

Hi @StevenF19 

If the Items property of the gallery is a collection, then the edit form must have a lookup to the underlying datasource being modified, ie. the source of the collection.  Gallery1.Selected will not work.  It must be Lookup(datasource, ID=Gallery1.Selected.ID) to specify the record being edited.  I used ID as an example but it could be any unique field  in the dataset. 

Helper II
Helper II

Thanks for the quick replies guys, but I think there's a bit of a misunderstanding. The Parent(Select) formula doesn't work at all in the gallery. I can't select an item in the gallery at all. I put a label with the text property GalleryName.Selected to test that it doesn't work and it stays blank when I try selecting an item in the gallery.

Can you show a screen shot

Hi @StevenF19 

Gallery.Selected refers to a record.  You cannot display a record in a label.  Put Gallery.Selected.Fieldname  in your label.

Your gallery is inside a datacard in your form...is that correct?

 

It sounds like maybe your Form settings is what is not allowing you to select the item in the Gallery. Either take the Gallery out of the Form or you will need to make sure the Form mode is set to Edit or New...it can't be View and you be allowed to click anything inside the form. 

Here's the test icon (the navy +) in my gallery with the OnSelect property as Select(Parent):

pic1.png

 

 

Here's the test label I placed (highlighted in red) and the text property. If the select in the icon was working, there'd be notes from the item in the gallery in the red highlighted box.

pic2.png

I would suggest you take the gallery out of the form. I have found that even when you do sub-galleries it does not allow you select items from the gallery well...so I don't think the gallery inside the form card works well.

 

If you are worried about keeping the scrolling ability you can put the data on a scrolling screen and put the form in one canvas, gallery in one etc.

@StevenF19 

 

Agreed...your gallery is not letting you select anything. You need to remove it from the Form. Selecting inside a form (for a gallery) and selecting items in subgalleries do not work well....it would be best to remove the gallery from the card in your form if you want to select anything. 

 

It works fine in a form and in a subgallery if you are just providing it as information to show...not well as interactive.

Helpful resources

Announcements
News & Announcements

Community Blog

Stay up tp date on the latest blogs and activities in the community News & Announcements.

Power Apps Community Call

Power Apps Community Call- January

Mark your calendars and join us for the next Power Apps Community Call on January 20th, 8a PST

PP Bootcamp Carousel

Global Power Platform Bootcamp

Dive into the Power Platform stack with hands-on sessions and labs, virtually delivered to you by experts and community leaders.

secondImage

Power Platform Community Conference On Demand

Watch Nick Doelman's session from the 2020 Power Platform Community Conference on demand!

Top Solution Authors
Top Kudoed Authors
Users online (6,140)