cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Frequent Visitor

Filter Gallery by Dropdown and a Search Box

Hi, 

 

i would like to filter my Gallery by a dropdown and a searchbox. My searchbox work very well but my dropdown doesn't work.

 

Here is what I put in Gallery > Items : 

 

Filter(CR_1; 'Nom du projet'.Value = Gallery1.Selected.Title; TextInput3.Text in 'Décision')

 

I can't take off the formula " 'Nom du projet'.Value = Gallery1.Selected.Title" because this gallery is linked to another Gallery.

 

Do you have an idea where can i put my formula for my dropdown ? 

 

Thanks a lot!

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Frequent Visitor

Re: Filter Gallery by Dropdown and a Search Box

Thank you for your advice I just made a test, and it worked :

 

Filter(CR_1; 'Nom du projet'.Value = Gallery1.Selected.Title; TextInput3.Text in Décision) 

 

I think its the dropdown that bothers me.

 

Thank you for your help!

 

 

View solution in original post

7 REPLIES 7
Highlighted
Dual Super User
Dual Super User

Re: Filter Gallery by Dropdown and a Search Box

Hey!

 

Please have a look at the screenshot below: 

 

MicrosoftTeams-image (11).png

 

Expression used: 

 

Filter('[dbo].[employees]',first_name=Gallery1.Selected.first_name && last_name = Dropdown3.SelectedText.Value && first_name = TextInput2.Text)

 

Note: 

 

This is a sample snippet that will work in your case also, please replace the actual values for all the attributes and controls. In this scenario, we are filtering Gallery2 based on the selected value in Gallery one, and also the firstname is mapped to search text and last name is mapped to dropdown. Since all the conditions are returning true, the record is populated in Gallery 2

 

Hope this Helped. 
 
Thanks, 

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

Highlighted
Frequent Visitor

Re: Filter Gallery by Dropdown and a Search Box

Hello! Thank you very much for your answer but unfortunetely my gallery still doesn't work...here a screenshot.

 

PB 2.png

 

Thank you for your help!

Highlighted
Dual Super User
Dual Super User

Re: Filter Gallery by Dropdown and a Search Box

Hey Can you please post the error that you are getting in English? 

 

Note: Ensure that the Gallery1.Selected.Title is getting mapped to the correct record of "Nom Du Projet.Value" attribute in cr_1. Verify that the data types of "Validation"and "Decision" are of type string (and if not, we will have to do a typecast to convert these values to strings). 

 

Thanks, 

 

Highlighted
Frequent Visitor

Re: Filter Gallery by Dropdown and a Search Box

yes in fact "Validation" is a yes or no type of data from a toglgle!

 

I haven't got a message error, just mine who said that "There is no data detected."

 

Thanks a lot!

Highlighted
Dual Super User
Dual Super User

Re: Filter Gallery by Dropdown and a Search Box

Hi @ClemD , 

 

Can you please verify the result that you are getting from Gallery1.selected.Title, you can put that into a new label, just to test out the returned data. The filters that you are using are correct, kindly verify the data that satisfies the condition (AND condition between all the three variants).
 
Thanks, 
Highlighted
Frequent Visitor

Re: Filter Gallery by Dropdown and a Search Box

Thank you for your advice I just made a test, and it worked :

 

Filter(CR_1; 'Nom du projet'.Value = Gallery1.Selected.Title; TextInput3.Text in Décision) 

 

I think its the dropdown that bothers me.

 

Thank you for your help!

 

 

View solution in original post

Highlighted
Dual Super User
Dual Super User

Re: Filter Gallery by Dropdown and a Search Box

Perfect!

 

Happy that it worked for you. 

 

Thanks, 

 

Helpful resources

Announcements
secondImage

Demo-Extravaganza 2020

Check out these cool Power Apps & vote on your favorite!

secondImage

Robotic Process Automation

Let's talk about the solution provided by Microsoft for Robotic Process Automation (RPA)

secondImage

Community Highlights

Check out whats happening in Power Apps

secondImage

Community User Group Member Badges

FIll out a quick form to claim your community user group member badge today!

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors
Users online (8,713)