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 / Filter. gallery view b...
Power Apps
Answered

Filter. gallery view based on user selection

(0) ShareShare
ReportReport
Posted on by 203

Hi,

 I have a gallery where, based on the user selection, the filter will be different.  When the user selects the option that they want to see (from an icon), the variable is updated with the icon value and this will be used in the filter.  But I'm sure the format in my items field is completely wrong!

 

Screen Shot 2021-03-19 at 13.00.58.png

 

My formula is:

Sort(
If(GallView = "1st Approval (Awaiting Price)",
Filter('Travel Approval Process','Pre-approved'.Value = "Approved" And 'Travel Approval Process',Approved.Value = "Pending")
,
If(GallView = "2nd Approval (Awaiting Ticket Issuance)",
Filter('Travel Approval Process',Approved.Value = "Approved" And 'Travel Approval Process','Tickets Issued'.Value= "No")
,
'Travel Approval Process')
),
Created,Descending)

Categories:
I have the same question (0)
  • Verified answer
    eka24 Profile Picture
    20,925 on at

    Try this modified formula. If you still have issues, clarify if you have two Galleries and also state the code for the variable:

     

    Sort(
    If(GallView = "1st Approval (Awaiting Price",
    Filter('Travel Approval Process','Pre-approved'.Value = "Approved" And Approved.Value = "Pending")
    ,
    If(GallView = "2nd Approval (Awaiting Ticket Issuance)",
    Filter('Travel Approval Process',Approved.Value = "Approved" And 'Tickets Issued'.Value= "No")
    ,
    'Travel Approval Process')
    ),
    Created,Descending)

    ------------

    If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

  • StephCORKING Profile Picture
    203 on at

    Hi @eka24 

     

    Brilliant!! 

     

    thank you so much 🙂

     

    Steph

  • SaiAnugrah_7860 Profile Picture
    2 on at

    I am building a reception management system . 

    When  the receptionist open the apps she needs to see the visitors of her current location . 
    For example : i have a list with receptionist email and their location .
    john@xyz.com --> India 
    Jack@xyz.com -- > USA 

    So when John logs in i want to see the data of only India and not USA similarly vice versa . Please suggest i also have other filter for the gallery that are working fine based on locations , name , time , date etc . i need to fit in my current scenario additional into my gallery items property .  Any suggestion would be highly appreciated .

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

Season of Sharing Community Challenge Launch!

Jump in, show your community spirit, and win prizes!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the April Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Vish WR Profile Picture

Vish WR 414

#2
Valantis Profile Picture

Valantis 387

#3
timl Profile Picture

timl 344 Super User 2026 Season 1

Last 30 days Overall leaderboard