web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Dynamically Display Im...
Power Apps
Answered

Dynamically Display Images Loaded to Power Apps 'Media' Section

(0) ShareShare
ReportReport
Posted on by 5,331 Moderator

I uploaded half-a-dozen images to my Power App.

Can I display each or those images in a Gallery Image control based on the choice in a Dropdown, similar to how I would if the images were in a SharePoint Library?

Categories:
I have the same question (0)
  • alexneedleman Profile Picture
    45 on at

    Hey Phineas,

     

    Do you mean using a Dropdown Combo Box essentially as a filter? Because if so, you definitely can! 
    What I would recommend is uploading those images to a SharePoint List with three columns:
    Column 1: Title (Give each image a name to identify them)
    Column 2: Image (Upload the images into this field)
    Column 3: Image Group (A Choice column with the options you'd like to be able to filter, ex. [Group1, Group2])

    Here's an example:

    alexneedleman_0-1702018000574.png

    Then, in your PowerApp, add a Drop down, and in its Items value, add all of the group names as choices in your list. In my example, my choices were Group1 and Group2, so in my Drop down menu, Items = ["Group1, Group2"]. 

    Then, add a gallery, and connect it to your SharePoint List. I would recommend getting rid of most labels and random things you don't want inside your gallery, and then for the Gallery's Items property, you can format your code similar to this:

    Filter(
     'Practice List',
     'Image Group'.Value = Dropdown1.Selected.Value
    )

    What this does is Filter any images you've uploaded based on your selected Drop down value. Here is how it looks like in action:

    alexneedleman_1-1702018321499.pngalexneedleman_2-1702018331787.png


    And just in case you (or someone reading this later) isn't familiar with how to attach images into a Gallery, use the Insert button up top to add an Image, then change it's Image value to ThisItem.(ImageColumnName). In my example, the Image property for the picture in my gallery was ThisItem.'Image Test' as that's the name of my SharePoint list column containing the image.

    Hope this helps!

  • v-mengmli-msft Profile Picture
    Microsoft Employee on at

    Hi @Phineas ,

     

    I'm assuming you want to display different images in Image control depending on the option within the dropdown.

    Please try this:

    1)Connect to your SP library.

    vmengmlimsft_1-1702020428344.png

    2)DropDown:

    Items:
    Distinct(LibraryName,Name)

    3)Image control:

    Image:LookUp(LibraryName,Name=Dropdown1.Selected.Value,Thumbnail.Large)

    vmengmlimsft_2-1702020685450.png

     

     

    Best regards,

    Rimmon

  • Phineas Profile Picture
    5,331 Moderator on at

    Yes, I know how to do it from

     A list or library.

     

    I'm Aaking if the can be accessed and filtered similar way from the 'Media' (im the left margin), area within Power Apps.

     

    I've uploaded the images to the app. When I open 'Media' in the left margin I can see the list of images.

     

    Can I now filter through them in some way from there, or must I use a list or library?

  • Verified answer
    v-mengmli-msft Profile Picture
    Microsoft Employee on at

    Hi @Phineas ,

     

    I'm afraid we can't use Media as a data source because it's not a database, and when you use filter functions like Filter, you'll find that there's no database for Media that you can use. I suggest you use list or library, and then refer to the method in my previous reply.

     

    Best regards,

    Rimmon

  • Phineas Profile Picture
    5,331 Moderator on at

    I figured as much, but wanted to make sure.

     

    Thank you

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 505

#2
WarrenBelz Profile Picture

WarrenBelz 502 Most Valuable Professional

#3
Haque Profile Picture

Haque 324

Last 30 days Overall leaderboard