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 / Need to create a compo...
Power Apps
Suggested Answer

Need to create a component which references sharepoint list

(2) ShareShare
ReportReport
Posted on by 90
I need to create a below component which should reference sharepoint list using the Gallery.
 
The image and the label like Home, Finance, Procurement and PO should be fetched dynamically from the SharePoint list. On clicking of the hamburger menu the component should expand and show the labels. The image and the labels should be clickable. It should also redirect to respective screens when clicked. The selected image/label should also be highlighted in proper color. May i know how to achieve this?
 
            
I have the same question (0)
  • Suggested answer
    Valantis Profile Picture
    4,847 on at
     
    This is doable with a canvas component and a SharePoint list. Here's the approach.
     
    SharePoint list setup:
    Create a list with columns: Title (label text), Icon (text, store icon name or image URL), ScreenName (text, the screen to navigate to), SortOrder (number).
     
    Component setup:
    Create a canvas component. Add a custom property called IsExpanded (boolean, input) to control the hamburger toggle. Add another custom property SelectedItem (text, output) to track the active item.
     
    Gallery inside the component:
    Set Items to: SortByColumns(YourSharePointList, "SortOrder", SortOrder.Ascending)
     
    For each gallery item:
    - Add an Image control, set Image to ThisItem.Icon (or use a hardcoded icon set mapped by name)
    - Add a Label, set Text to ThisItem.Title, set Visible to the IsExpanded property
    - Set the gallery item's Fill to: If(ThisItem.Title = varSelectedNav, RGBA(0,120,212,1), RGBA(0,0,0,0)) for highlight
     
    Navigation on click:
    On the gallery item's OnSelect:
    Set(varSelectedNav, ThisItem.Title); Navigate(LookUp(colNavScreens, Title = ThisItem.Title).ScreenName)
    Since Navigate() doesn't accept a text string directly as a screen reference, the cleanest pattern is to use a Switch statement:
    Switch(ThisItem.ScreenName, "Home", Navigate(HomeScreen), "Finance", Navigate(FinanceScreen))
     
    Hamburger button:
    Add a button outside the gallery with OnSelect: Set(varExpanded, !varExpanded) and pass varExpanded into the IsExpanded component property.
    One thing to confirm: are your icons stored as image URLs in SharePoint, SVG strings, or are you using the built-in Power Apps icon set? That determines how to set the Image property in the gallery.
     

     

    Best regards,

    Valantis

     

    ✅ If this helped solve your issue, please Accept as Solution so others can find it quickly.

    ❤️ If it didn’t fully solve it but was still useful, please click “Yes” on “Was this reply helpful?” or leave a Like :).

    🏷️ For follow-ups  @Valantis.

    📝 https://valantisond365.com/

    💼 LinkedIn

    ▶️ YouTube

  • Poweruser32490 Profile Picture
    90 on at
     
    Image is an image column in SharePoint
  • Suggested answer
    Sunil Kumar Pashikanti Profile Picture
    2,060 Moderator on at
     
    Please follow @Valantis suggestion.
     
    For more clarity and some background follow below references:

    What YOU should follow

    For your exact requirement:

    1. Start with:
    2. Then:
    3. Then:

    One-line takeaway: Combine Gallery + Component + Navigate() + variable for toggle → you will get exactly the menu UI you showed.

    ✅ If this answer helped resolve your issue, please mark it as Accepted so it can help others with the same problem.
    👍 Feel free to Like the post if you found it useful.

    Sunil Kumar Pashikanti, Moderator
    Blog:
     https://sunilpashikanti.com/posts/
  • Vish WR Profile Picture
    2,285 on at
     

    Besides this i recommend loading your SharePoint list into a Collection on the App.OnStart. This ensures your navigation loads instantly across all screens and minimizes the number of calls to your SharePoint site.

     
     

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
Vish WR Profile Picture

Vish WR 936

#2
Valantis Profile Picture

Valantis 602

#3
11manish Profile Picture

11manish 598

Last 30 days Overall leaderboard