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

Gallery default selected based on another gallery selected

I have two galleries on two separate pages.  Both galleries are the exact same, tying to the same data source and filters. When I select an item on the first gallery it navigates to the second page. I want the gallery on the second page to default to the selection from the first gallery. 

 

 

6 REPLIES 6
Silvester
Super User
Super User

Hello @haybob ,
Try setting up a variable on the OnSelect property of the first gallery. 

Set(VarItem, ThisItem)

On the second gallery, set the DefaultSelectedItem to the "VarItem".
Please accept as a solution if it works for you. Dont forget to give it a "Like" as well


Did you like my post? Please give it a thumbs up! Did I resolve your issue? Please click Accept as Solution to close the thread and so other members of the community can find it easily.

I only see Default as an option and setting it to the variable doesn't work.

Silvester
Super User
Super User

Kindly try it on the "Default"

Did you like my post? Please give it a thumbs up! Did I resolve your issue? Please click Accept as Solution to close the thread and so other members of the community can find it easily.
NandiniBhagya20
Solution Sage
Solution Sage

Hi 

If you want to set gallery2’s default property based on gallery1 selection then you can use below formula on Default property of gallery 2

LookUp(ListName, ID = Gallery1.Selected.ID)


Did you like my post? Please give it a thumbs up! Did I resolve your issue? Please click Accept as Solution to close the topic and so other members of the community can find solutions more easily.

I get an error when attempting the formula. Invalid formula. Expected a value compatible with 'items'.

Can you please share the screenshot with error and the property where you are inserting this formula


Did you like my post? Please give it a thumbs up! Did I resolve your issue? Please click Accept as Solution to close the topic and so other members of the community can find solutions more easily.

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Community Call Conversations

Introducing the Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (2,749)