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 / Gallery Calculation in...
Power Apps
Answered

Gallery Calculation in label

(0) ShareShare
ReportReport
Posted on by 109

Hi ,

 

I could not do the Label 4 Calculation. Can you help me.

 

Gallery Powerapps.png

Categories:
I have the same question (0)
  • RandyHayes Profile Picture
    76,297 Super User 2024 Season 1 on at

    @dursunzeeee 

    Items property of your Gallery:

    With({_items: yourCurrentItemsProperty}},
    
     AddColumns(_items,
     "_sum", Sum(_items, Label_3ColumnName)
     )
    )

    Label_4 Text:

    Text((ThisItem.Label3ColumnName / ThisItem._sum) * 100, "#%")

     

    I hope this is helpful for you.

  • Drrickryp Profile Picture
    Super User 2024 Season 1 on at

    @dursunzeeee 

    For a more detailed explanation of how to set up a gallery in PowerApps see below.  It has a calculation for a sum of the $ amounts in the gallery.!.jpg

  • dursunzeeee Profile Picture
    109 on at

    I cant "qty/allqty"

    dursunzeeee_0-1615138371702.png

     

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

    @dursunzeeee 

    What is your Items property for the Gallery?

  • dursunzeeee Profile Picture
    109 on at

    dursunzeeee_0-1615138892355.png

     

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

    @dursunzeeee 

    I am not understanding...you're not using the Items property that I suggested you should implement.

    Your formula should be:

     

    With({_items: Filter(Menu_Grup; Custom_Grup = Dropdown17_5.Selected.Result)}};
    
     AddColumns(_items;
     "_sum"; Sum(_items; yourQtyColumnName)
     )
    )

     

    Replace yourQtyColumnName in the above with the name of the column in your datasource that you want to have the sum of.

     

    For your Percentage column - this formula on the Text property:

    Text((ThisItem.yourQtyColumnName/ ThisItem._sum) * 100; "#%")

    And again, replace the column name in the above. 

  • dursunzeeee Profile Picture
    109 on at

    dursunzeeee_1-1615142060626.png

     

    When gallery3_4 items write your code 

     

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

    @dursunzeeee 

    Sorry, extra curly bracket in my last message:

    Change to:

    With({_items: Filter(Menu_Grup; Custom_Grup = Dropdown17_5.Selected.Result)};
    
     AddColumns(_items;
     "_sum"; Sum(_items; yourQtyColumnName)
     )
    )
  • dursunzeeee Profile Picture
    109 on at

    Thank you very much for your support. I just started learning Powerapss.

  • dursunzeeee Profile Picture
    109 on at

    Hello again, in the same way, if I need to do the second calculation, how should I proceed?

     

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

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 343 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard