cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Ash_App_Dev
New Member

Moving images location based on the visibility of other images

I'm trying to create an app to track training badges our users are earning. I currently have a total of 14 different badges and 145 trainees to account for. I want to be able a to display the badges a trainee has on their item in a gallery view. However I want the images' location to changes based on if the images of the other badges are visible.

For example:

Ash_App_Dev_0-1638545386060.png

Billy Real-Name has the power automate, excel, forms, and outlook badges. Where Testy McTesterson only has the  power automate, excel, and outlook badges. Because Testy doesn't have the forms badge but does have the outlook badge, the outlook badge moves over to be next to the next closest badge.

 

I have no Idea how to even start going about doing this or if it's even possible. My first Idea was a bunch of if statements but there has to be a more straightforward way to go about it.

1 REPLY 1
AmDev
Super User
Super User

Hi @Ash_App_Dev 

 

You could have the badges stored with a corresponding ID column and IDs running in sequence and then sort your gallery smallest to biggest ID along each horizontal gallery. So a user with corresponding badges for IDs 1,2,5,7 then gets badge 3, it will slot in at the right place due to your sorting by ID on the Gallery i.e. 1,2,3,5,7

 

Hope this helps.

Helpful resources

Announcements
PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

Microsoft Build 768x460.png

Microsoft Build is May 24-26. Have you registered yet?

Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.

May UG Leader Call Carousel 768x460.png

What difference can a User Group make for you?

At the monthly call, connect with other leaders and find out how community makes your experience even better.

Top Solution Authors
Top Kudoed Authors
Users online (3,658)