cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Post Patron
Post Patron

show gallery items based on selected item with same parent ID

I have a form with a gallery next to it.  I wish to dsiplay the other entries with the same parentID as the current entry.

have tried using Default(Childdata.parentID).  I have brought in the parentID in as a lookup and wonder if thats where ive gone wrong.

1 ACCEPTED SOLUTION

Accepted Solutions

Hi @StuCundy ,

Could you please share a bit more about your HOSTCHILDTest data source? Is it a SP List?

Could you please show more details about the FamilyID field? Is it a LookUp type column in your SP list?

Further, do you want to display other child items (whose have same ParentID value as the current record within the Edit form) within the Gallery1?

 

If the HOSTCHILDTest data source is a SP List, and the FamilyID field is a LookUp type field, please consider take a try with the following workaround:

Set the Items property of the Gallery1 to following:

Filter(
       HOSTCHILDTest,
       FamilyID.Value = DataCardValue9.Selected.Value
)

Note: If the FamilyID field is a LookUp type field, the DataCardValue9 would be rendered as a ComboBox within your Edit form.

 

If the FamilyID field is just a normal Text type column, please consider modify above formula as below:

Filter(
       HOSTCHILDTest,
       FamilyID = DataCardValue9.Text
)

 

Please consider take a try with above solution, check if the issue is solved.

 

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

6 REPLIES 6
Super User III
Super User III

Please explain futher. Is the Childdata a different table?

 Insert a another Gallery2 and tie that to the form. Then on Gallery2 Items put:
    Filter(Childdata,ID=Gallery1.Selected.ID)

 

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

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 @eka24 

I have the one set of child data.  I have the form reading the child data and gallery reading the same child data on the same screen next to it.  Sp what ever child is selected at the time I wish to show all the other child items in the Gallery1 of the same ParentID

 

In this case

ParentID=FamilyID=DataCardValue9

Gallery1 IDItem Text=ThisItemFamilyID.Id

 

I have tried the following

 

Filter(HOSTCHILDTest,FamilyID=Gallery1.Selected.FamilyID)

Filter(HOSTCHILDTest,FamilyID=Gallery1.Selected.FamilyID.Id)

Filter(HOSTCHILDTest,DataCardValue9.Selected.Value=Gallery1.Selected.FamilyID)

 

I think I'm close...

Hi @StuCundy ,

Could you please share a bit more about your HOSTCHILDTest data source? Is it a SP List?

Could you please show more details about the FamilyID field? Is it a LookUp type column in your SP list?

Further, do you want to display other child items (whose have same ParentID value as the current record within the Edit form) within the Gallery1?

 

If the HOSTCHILDTest data source is a SP List, and the FamilyID field is a LookUp type field, please consider take a try with the following workaround:

Set the Items property of the Gallery1 to following:

Filter(
       HOSTCHILDTest,
       FamilyID.Value = DataCardValue9.Selected.Value
)

Note: If the FamilyID field is a LookUp type field, the DataCardValue9 would be rendered as a ComboBox within your Edit form.

 

If the FamilyID field is just a normal Text type column, please consider modify above formula as below:

Filter(
       HOSTCHILDTest,
       FamilyID = DataCardValue9.Text
)

 

Please consider take a try with above solution, check if the issue is solved.

 

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

Dear @eka24 

 

Yes my Child List and Parent List are SP lists.  The FamilyID field is my lookup in the child SP list.  Yes I wanted to display items with the same ParentID as the current item within the edit form.

 

Both your filter functions were spot on thankyou.  I was so close so thanks again.

@eka24 

I was wondering if you could help me on another issue in this topic.  I now have a Three cluster list relationship with a junction list bring in 2 parent lists.  Trying to just link one of the parent lists to the junction list at this stage using your formula

 

"Group" is a parent, "Junction: is the child and also has a second parent relationship in another list.

 

Filter(Junction,ID=Gallery1.Selected.GroupID)

 

It the issue to do with the 2nd parent item in the Junction table I wonder?

@eka24 Sorry that should have been Filter(Junction,GroupID=Gallery1.Selected.ID)

Helpful resources

Announcements
secondImage

Experience what’s next for Power Apps

Join us for an in-depth look at the new Power Apps features and capabilities at the free Microsoft Business Applications Launch Event.

Power Apps Community Call

Power Apps Community Call: February

Did you miss the call? Check out the Power Apps Community Call here.

New Power Super Users

Congratulations!

We are excited to announce the Power Apps Super Users!

New Badges

New Solution Badges!

Check out our new profile badges recognizing authored solutions!

Top Kudoed Authors
Users online (23,870)