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

Gallery.Selected changing after submitting Edit Form

I've seen a few similar posts about this issue on here, but it looks like the most recent is from 2018 or so and I'm really hoping there's a solution now.

 

I have a PowerApp being used for tracking child enrollment in our preschools. It's a pretty big app with a page per stage of the enrollment process, and everything on each page is designed to display the Gallery.Selected Child. Each child has a unique ChildID that is identical across all SP lists this thing kicks back into. We have noticed that when someone employs a filter on the main gallery (such as typing in the beginning of a child's name into the search bar), after submitting an Edit Form on any of these pages the app will save the changes, but switch to the next child listed on the filter. As far as I can tell this only happens when there's a filter employed on that initial gallery, and it seems to be happening just about EVERY time. Anyone have any advice?

1 ACCEPTED SOLUTION

Accepted Solutions
zmansuri
Community Champion
Community Champion

Set variable on gallery's icon.

Set(varRecord,ThisItem)

Wherever you are using Gallery.Selected. Use varRecord instead. For eg. Form's item property.

 

Write this in Gallery.TemplateFill

If(varRecord.ID=ThisItem.ID,AliceBlue)

This way you'll know which record is selected right now.

if you need more help. @Shanescows  has an amazing video on it.

https://youtu.be/691pRyRHWBU

 

View solution in original post

2 REPLIES 2
zmansuri
Community Champion
Community Champion

Set variable on gallery's icon.

Set(varRecord,ThisItem)

Wherever you are using Gallery.Selected. Use varRecord instead. For eg. Form's item property.

 

Write this in Gallery.TemplateFill

If(varRecord.ID=ThisItem.ID,AliceBlue)

This way you'll know which record is selected right now.

if you need more help. @Shanescows  has an amazing video on it.

https://youtu.be/691pRyRHWBU

 

View solution in original post

I knew it was going to be something obvious! Thank you!

Helpful resources

Announcements
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

PowerPlatform 768x460.png

Microsoft Learn

Check out our new Discover Your Career Path blog post series and get all the details.

Users online (3,066)