web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Power Apps - Building Power Apps
Unanswered

Filter a gallery on value in variable

(0) ShareShare
ReportReport
Posted on by 45

I have a gallery ModulesGallery that is populated from data source Modules_Locations. The gallery has 2 items, MIN and Status.
There is a button that onSelect populates a variable varFilterStatus with "Green".
I want the gallery to then be filtered to all records with Status="Green" so have the Items property of the gallery as 
Filter(Module_Locations,Status= varFilterStatus);
The ; at the end of the Filter function above has a red line under it with the error
Expected operator. We expect an operator such as +, *, or & at this point in the function.
I do not see that requirement in the syntax of the Filter function. Can someone please tell me what I am doing wrong.

Categories:
I have the same question (0)
  • Drrickryp Profile Picture
    Super User 2024 Season 1 on at
    Re: Filter a gallery on value in variable

    @murray7 

    Try Filter(Module_Locations,Status.Value= varFilterStatus);

  • murray7 Profile Picture
    45 on at
    Re: Filter a gallery on value in variable

    Status.Value also gave an error. I have resolved the issue which was the fact Status had not been initialised when this screen was visible.

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

Coming soon: forum hierarchy changes

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 803 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 314 Super User 2025 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 253 Super User 2025 Season 2

Last 30 days Overall leaderboard