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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / formula to create perc...
Power Apps
Unanswered

formula to create percentage in pie chart?

(0) ShareShare
ReportReport
Posted on by 42

Hello everyone!

 

I really, really need help with a formula to create percentages in a pie chart.

 

1. I have a SharePoint list.

 

image.png

 

2. This SharePoint list had been used into gallery ( GalleryEdit1 ) where I filtered based on the specific user ( User().email ).

 

marsyazahid72_0-1616285047631.png

 

3. I really, really need to create a pie chart in Power Apps that can calculate the percentage of each column in pie chart as below image (which I draw by myself for the expected result) where the percentage can be increased/decreased if any changes in the gallery.

 

marsyazahid72_1-1616286238923.png

4. The calculation that I can figure out is this

each column : FPoints of SRC / total FPoints *100%
total FPoints : 
(FPoints of SRC + FPoints of Clubs/Society + FPoints of Special Events + FPoints of Ad-Hoc Teams)

 

Highly appreciated anyone's attention and guidance.🤗

 

 

Categories:
I have the same question (0)
  • marsyazahid72 Profile Picture
    42 on at

    I also had tried to use my friend's code where she gets the result as below image but when I apply to my case, unfortunately, it did not works😢.

    The pie chart she had createdThe pie chart she had created

    her code for the pie charther code for the pie chart

    Anyone could help me?😢

  • Verified answer
    RandyHayes Profile Picture
    76,297 Super User 2024 Season 1 on at

    @marsyazahid72 

    Consider the following:

    Change your Items property of the Pie Chart to -

    AddColumns(
     AddColumns(
     GroupBy(
     GalleryEdit_1.AllItems,
     "EC_PA_Cri1",
     "_recs"
     ),
     "_total", CountRows(GalleryEdit_1.AllItems),
     "_recTotal", CountRows(_recs)
     ),
     "_label", EC_PA_Cri1 & " : " & Text((_recTotal/_total)*100, "%0")
    )
    

    Set the Series on your PieChart to  _recTotal

    Set the Labels on your PieChart to _label

     

    I hope this is helpful for you.

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

Forum hierarchy changes are complete!

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 796 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 327 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard