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 / Sum function in a coll...
Power Apps
Unanswered

Sum function in a collection

(0) ShareShare
ReportReport
Posted on by 66

Hi!

I have a Gallery which has a record of item prices. The records to the gallery are added from a form. I am trying to write a sum function that would display the total sum of item prices:

ekoz21_1-1625630293865.png

 

I used the following formula:

"Total Sum, Eur: "& Sum(ColStolenArticles, Value(Suma_lbl.Text))


However, I keep getting a blank outcome. Any help is much appreciated!

Categories:
I have the same question (0)
  • Verified answer
    Sid_Jafri Profile Picture
    478 on at

    Hi @ekoz21 ,

    You better use the collection value and sum up. e.g. use the collection column name for unit price and amount
    "Total Sum, Eur: "& Sum(ColStolenArticles,  unitprice * amount)

    Or you can use

    "Total Sum, Eur: "& Sum(Gallery.AllItems, Value(Suma_lbl.Text))

     

    Make sure that Suma_lbl.Text doesn't contains text value as I seen above have some text of Sum, Eur:

    Please Thumbs up and accept as solution if my post helped you solve your issue.

  • Verified answer
    Dipak_Shaw Profile Picture
    108 on at

    Hi, 
    if you want to sum the items of a gallery outside the gallery.

    You should use 

    "Total Sum, Eur: "&Sum(Gallery1.AllItems,SumPrice)

    Where -

    Gallery1 = Your gallery name.

    SumPrice = The Field that you want to sum.

    Try it out, It will definitely work.

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

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