cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Lily_Chen
Regular Visitor

Applying multiple filters to canvas app gallery

Hi, 
I am trying to fulfill the requirement: View a list of animals at the selected local shelter that are ready to be fostered.
And I need some help identifying what's wrong with my fx formula.
I set up a drop down list called"Select local shelter name" as one of the filtering metric. 
And below is the fx formula I have for now. It doesn't work.

Filter
(Animals,
And('Shelter Status (Animals)'.'Ready for Foster'),('Shelter Name'='Select local shelter name'.SelectedText.'Shelter Name'))
 
Thank you for any solutions.
1 ACCEPTED SOLUTION

Accepted Solutions
Lily_Chen
Regular Visitor

Hi Thank you for helping me debug!

@BCBuizer The formula still doesn't work but at least now I know I should use "Selected" instead!

@Grkm_A I think your code looks correct and I did tried, but it says"Delegation warning. The "Text" part of this formula might not work correctly on large data sets."

 

But good news, in the end I got things right with the method in this video:

https://youtu.be/5dSk5iOgT68?si=WQgeLJfm33n3OPKM

 

Now my code looks like this:

Filter(
    Animals,//The table that contains all the animal information
    'Shelter Name' = 'DD shelter name'.Selected.'Shelter Name',//Dropdown item which selected from the drowdown item named as "DD shelter name"
    'Shelter Status' = 'CB shelter status'.Selected.Value//Combo Box item which selected from the Combox Box item named as "CB shelter status"
)

 

 

P.S. I deselected the "allow multichoice selections" in the property setting.

View solution in original post

5 REPLIES 5
BCBuizer
Multi Super User
Multi Super User

Hi @Lily_Chen ,

 

I see you are using the SelectedText property which is actually deprecated. Instead you should use the Selected property:

 

 

Filter(
    Animals,
    'Shelter Status (Animals)'.'Ready for Foster'),
    'Shelter Name'='Select local shelter name'.Selected.'Shelter Name'
)

 



Did you like my post? Please give it a thumbs up! Did I resolve your issue? Please click Accept as Solution to close the topic and so other members of the community can find solutions more easily.

Hi,

 

I have a solution for the filtering with 2 values in gallery. I used the formula that shown below and it worked. 

 

Filter(
    Animal_Details, // Table that the data shown and applying filters
    NewShelterName = SheltersDropDown.SelectedText.Value, // Dropdown item which selected form the drowdown item name as SheltersDropDown
    Text(NewShelterStatus) = "Ready for Foster" // ShelterStatus is Ready for Foster i the another filtering value
)
Lily_Chen
Regular Visitor

Hi Thank you for helping me debug!

@BCBuizer The formula still doesn't work but at least now I know I should use "Selected" instead!

@Grkm_A I think your code looks correct and I did tried, but it says"Delegation warning. The "Text" part of this formula might not work correctly on large data sets."

 

But good news, in the end I got things right with the method in this video:

https://youtu.be/5dSk5iOgT68?si=WQgeLJfm33n3OPKM

 

Now my code looks like this:

Filter(
    Animals,//The table that contains all the animal information
    'Shelter Name' = 'DD shelter name'.Selected.'Shelter Name',//Dropdown item which selected from the drowdown item named as "DD shelter name"
    'Shelter Status' = 'CB shelter status'.Selected.Value//Combo Box item which selected from the Combox Box item named as "CB shelter status"
)

 

 

P.S. I deselected the "allow multichoice selections" in the property setting.

Hi @Lily_Chen ,

 

Yes, I saw that error too. However, since only one "shelter status" was required in the pdf file, I added it as a constant to the formula. Although we can multiply this as a list. (Text(NewShelterStatus) in ["filter1","filter2"... ]) I think the error is caused by setting this variable as constant.

Also, if I understand correctly, only those with shelter status "ready for foster" will be listed?

GeekSkier
Frequent Visitor

Hi - you can also do it without filtering. This is how I did it...

  • Over in my Animals table, I created a new view called 'Ready for Foster'. The VIEW is filtered so it only shows animals with that status.
  • Then, when I created my gallery, I set the datasource to the Animals database and the VIEW to the view I created.

GeekSkier_0-1715866342028.png

 

Helpful resources

Announcements

Important Update | Power Up Community READ ONLY July 22 – July 28

Dear Community Members, As you may have read, the Power Platform communities are transitioning to a new platform and to access will be set to READ-ONLY mode during the transition. Key DatesTo ensure current learners have adequate support in the final week of the cohort, the Power Up Program Community will transition to READ-ONLY mode starting July 22nd, the platform will transition to READ-ONLY mode until July 28th. Power Apps, Power Automate, and Power Pages communities will be read-only July 16-22, 2024.During this period, members will not be able to start new threads or Kudo, Comment, or Reply to any posts, but will be able to search and review past threads or solutions. On July 22nd, please be on the lookout for a message sent to the email address registered on your community profile. This email is crucial as it will contain your unique code and link to register for the new platform encompassing all of the communities. Learners will be able to sign in to the new Power Up Program community experience, starting July 29th. If you registered for community using your learnwithpowerup account, you will not receive an email, but should be able to sign in successfully if you are signed in to My hub.  If you need help with your community account, please submit a request at aka.ms/PPCommSupport We appreciate your understanding and cooperation during this transition. Stay tuned for the exciting new features and a seamless community experience ahead! 

Learn what to expect in the Power Up Program

Since its inception in 2022, the Power Up Program has evolved based on feedback from learners and Microsoft Partners and customers. Today's Power Up learners can expect to learn the fundamentals of Microsoft Power Platform in the accelerated seven-week, video-based Power Up Maker course.   Hear from Principal Program Manager, Dimpi Gandhi to discover the latest enhancements and meet the Microsoft MVPs, Rory Neary and Charlie Phipps, who partnered with the Microsoft Power Up Program to create the Power Up Maker course to guide learners to use the Microsoft Power Platform to develop custom applications, build dazzling report dashboards, or create efficiencies through automation.  

Welcome to the Power Up Program Community

The Power Up Program is a free upskilling program where nontechnical people can learn the fundamentals of Microsoft Power Platform. The Power Up Maker course is a seven-week self-paced virtual learning plan that include video-based objectives featuring Power Apps, Power BI and Power Automate.  As a member of the Power Up Community, you can grow your skills and build connections. You can post questions to get help with the curriculum and hands-on exercises from experts and peers in the product boards.  Check out the Community Information & Feedback board to find help or provide feedback with the community experience, and please take time to post in the Social board to tell us more about yourself. If you're new to the Power Up Program and looking for information to register. You can sign up at PowerUp.Microsoft.com.

Users online (1,952)