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 on Gallery Item...
Power Apps
Unanswered

Filter on Gallery Items based on Buttons

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hello,

 

I am creating a power app with SharePoint List. I want to filter my list for one of column value. I created multiple buttons and want to retrieve data based on my button click. 

 

main.PNG

 

I have to a dropdown column naming Status in my list with various values such as Draft/ PD Check/ BA Check etc. I want to gat data with Status as Draft with my Button named Draft and so on for other.

 

I tried this formula for 1st case:

Gallery.Items: Filter(PID,StartsWith('PID Type'.Value, Dropdown1.Selected.ColumnStart) && If(Draft.AutoDisableOnSelect,StartsWith('PID Status'.Value, Draft.Text),true))

But it always shows data only with status draft.

 

Can someone help.

 

Categories:
I have the same question (0)
  • v-yutliu-msft Profile Picture
    Microsoft Employee on at

    Hi @Anonymous ,

    Could you tell me the relationship between the buttons and the drop down?
    Whether do you want their relationship is "AND" or "OR" ?

    For example, if you click "Draft" button and you choose "All" in drop down, what kind of data do you want to display?

    Is 'PID Status' data type choice? single choice?
    I assume that it is a single choice column.

    I firstly made a test for only having some buttons to filter. (about the drop down, I need your answer)

    1)insert some buttons.

    2)set Draft button's OnSelect: 

    Set(var,"Draft")

    set PD Check button's OnSelect:

    Set(var,"PD Check")

    .....

    Set the gallery's Items:

    If(IsBlank(var)||var="All",PID,Filter(PID,PID Status'.Value=var))

    Then the gallery's Items will filter based on the button that you click.

     

     

     

    Best regards,

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Sorry for late reply.

     

    Now, me requirement changed. I need to apply multiple filter with buttons only.

     

    When I click the button I should get Item with status "Draft" and Item Type as "WLI".

     

    Is it possible to apply multiple filter?

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 Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 324 Most Valuable Professional

#2
11manish Profile Picture

11manish 193

#3
Valantis Profile Picture

Valantis 138

Last 30 days Overall leaderboard