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 / Multiple Filter in Gal...
Power Apps
Answered

Multiple Filter in Gallery and also with Buttons

(0) ShareShare
ReportReport
Posted on by 1,119

Hi All,

 

there are more and more topics on this subject, but still i am looking for some help.

On gallery i have the below formula

 

Filter(datasoure, Department = dd_department.Selected.Value && IssueStatus = dd_issue.Selected.Value)

Basically i have two dropdowns for selecting department and issue status. Issue status is like new, open, inprogress, closed.

Now i also have button for all the issue status. I want to combine the filter formula to work with both issue status drop down or by clicking the button.

 

can any one pleas ehelp.

Categories:
I have the same question (0)
  • KvB1 Profile Picture
    1,596 on at

    If you want to have an option to show all the issue status, it would be nicer to add an If( function to check whether anything has been selected at all in that dropdown, and if not, bypass that part of the filter

     

    The other option would be to set a variable when clicking the button, which would do the same

  • Verified answer
    Adrian_Celis Profile Picture
    1,652 Moderator on at

    Hi @venka91 

    The trick here is to make your department and issue value a variable.
    Let's name your department value as varDepartment and your issue value as varIssue

    In the OnChange property of your Dropdown, use this code:
    For Department

    UpdateContext({varDepartment:dd_department.Selected.Value})

    For Issue

    UpdateContext({varIssue:dd_issue.Selected.Value})

    Then use this formula in the Items property of your gallery

    Filter(datasoure, Department = varDepartment && IssueStatus = varIssue)

    Now for your buttons, you can use the UpdateContext and assign it to varIssue depending on which button.

    So for your 'New' issue button, use:

    UpdateContext({varIssue:"New"})

     

  • venka91 Profile Picture
    1,119 on at

    Excellent. This is worked like a charm. I was worried bit because i have multiple screen and multiple filters for my Gallery. Also, in the past i encountered issue, if i do any change to Gallery Filter. For some reason, power apps was keep saying error though formulas were right. Only option, i have to close the App and Re-open.

     

    But this time, adding this context variable did not give me any error. It went very smoothly. And i can achieve the functionality what i wanted.

     

    Thanks a lot.

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 May Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Valantis Profile Picture

Valantis 414

#2
WarrenBelz Profile Picture

WarrenBelz 377 Most Valuable Professional

#3
Kalathiya Profile Picture

Kalathiya 315 Super User 2026 Season 1

Last 30 days Overall leaderboard