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 / Filtering Total Count ...
Power Apps
Answered

Filtering Total Count of 1 column

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hi guys,

 

So i have been asked to create an app for the headcount of our company and unfortunatly i am limited on how it should look and be used. I have created a sharepoint list for each department and i have managed to get the edit screen to work perfectly, it's exactly how they want it to look.

They now want a gallery that shows the total number of direct employees and the total number of indirect employees for each department. I cannot figure this out.

My sharepoint list (names and titles edited out for confidentiality)

manufacturing.PNG

My edit screen which they want to be the default layout for each department / full summary

editscreen.PNG

 

This would be how they want the summary to look - So they want to keep the same layout but have the direct and indirect total number of fields populated for Current Headcount, apr, may etc
Direct Indirect.PNG

 

Does this make sense? Is it possible? Sorry for my lack of knowledge here! Hoping someone can help!

Categories:
  • Verified answer
    RandyHayes Profile Picture
    76,299 Super User 2024 Season 1 on at

    @Anonymous 

    If I understand you correctly, you are creating a Summary screen that will only show direct and indirect from your data source.

    Unlike the first screen which shows the individual names of people and the counts, this summary screen is only based on the Direct and Indirect totals.

    The only confusion I have is that you refer to this as an Edit screen...are you implying this is not a Gallery and that you are using something else, or is it just a generic name?

    If the above is correct, then you will need to do some grouping.

    For your Gallery Items, you will make the formula similar to this:

    GroupBy(yourDataSourceName, "Direct & Indirect", "Items")

    Obviously replacing the yourDataSourceName with the actual name of your data source and the Direct & Indirect with the recognized column name for that in PowerApps.

    This will create a table for the gallery that will have two columns, the Direct & Indirect column and the Items column.  The Direct and Indirect column will be a distinct list of the Direct and Indirect value.  The Items column will contain a table of all the rows that match that value.

     

    Now, in your Gallery, for each textbox you have, you can simply use the following formula:

    Sum(ThisItem.Items, Apr)

    This can be done for each column you have in the list and for each textbox you have.

    That will give you the sums you are looking for.

     

    I hope this is clear and helpful for you.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    @RandyHayes  - this is perfect! Thank you so so so much!

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 220 Super User 2026 Season 2

#2
WarrenBelz Profile Picture

WarrenBelz 189 Most Valuable Professional

#3
Mohsin Ali Profile Picture

Mohsin Ali 139

Last 30 days Overall leaderboard