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 / PowerApp - Filter cont...
Power Apps
Unanswered

PowerApp - Filter content in gallery based on toggle

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hi


I have an purchase app that lookup an Sharepoint list, that contains items for this purchase powerapp.

Some items is accessories to other items, therefor I have a column named "related-items" which has the item ID of all the accessories with a ";" delimiter.

Example:
item1 is an iPhone, and Item2 is a cover for that type of iPhone. Therefor the item1 have entered the ID for the item2 (the cover), in a dedicated column for this information "related-items".

 

I'm working on a filter with a Toggle on each item in the PowerApp Gallery, that if you click "Accessories toggle" it filters on the items which has a matching ID = to the current items ID on the column "related-items". But I can't get this working with an IF statement.

Do anyone made something similar?

 

Categories:
I have the same question (0)
  • LuizVicente Profile Picture
    984 Super User 2024 Season 1 on at
    If(
     Toggle.Value, // No need to compare with true (Toggle.Value = true)
     Filter(
     MyDataSource,
     ID = ThisItem.ID // I assume Toggle is inside the gallery
     )
    )

    ... does not work? If it doesn't work, share some images to help...

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

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 329 Most Valuable Professional

#2
11manish Profile Picture

11manish 209 Super User 2026 Season 2

#3
Mohsin Ali Profile Picture

Mohsin Ali 179

Last 30 days Overall leaderboard