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 / Adding a Filter to a G...
Power Apps
Suggested Answer

Adding a Filter to a Groupby for a Gallery

(0) ShareShare
ReportReport
Posted on by 302
My current code for the home gallery 
GroupBy(AddColumns(Grants,ProjectText,Project.Value),ProjectText,Data)
 
Description: I am building a platform for users to mark tasks that are assigned to them complete/put on hold/make comments on them.

My problem is on home screen I have everything grouped by the Project choice column in a sharepoint list. I would like to filter it out to only show users projects that they have tasks assigned to them.

How could this be accomplished?
Categories:
  • ronaldwalcott Profile Picture
    3,914 Moderator on at
    Wouldn't you just replace Grants in your GroupBy with something like Filter(Grants, column in grants = the current user) ?
    How do you identify the projects assigned to a user? Did you use User() to associate the projects with a user?
     
  • Suggested answer
    CU07111156-1 Profile Picture
    6 on at
    Hi

    Hopefully I've understood this request, my suggestion:  Filter the results before grouping
    GroupBy(
     AddColumns(
      Filter( Grants, user = current user ),
     ProjectText,Project.Value),
    ProjectText,Data)

    Alternatively, Filter the Resulting group
    Filter(
     GroupBy(AddColumns(Grants,ProjectText,Project.Value),ProjectText,Data),
     user = current user).

    Depending on the layout / Home screen you could also add a "Show My Tasks" Button / Toggle and add a IF to the filter
    Something along the lines of 
     If "My Tasks" equal true
     then Filter & Groupby xyz
     else GroupBy xyz.

    Hope that helps

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

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 226 Super User 2026 Season 2

#2
WarrenBelz Profile Picture

WarrenBelz 191 Most Valuable Professional

#3
Mohsin Ali Profile Picture

Mohsin Ali 167

Last 30 days Overall leaderboard