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 / Sum of label and value...
Power Apps
Answered

Sum of label and value from column of a sharepoint

(0) ShareShare
ReportReport
Posted on by 2

I had a Label named "claimAmount"  and i would like to Sum value of claimAmount with the existing data in sharepoint's List column named "Total_Medical" based on user Email

Sharepoint list - "employeeBalance"

Column name - "Total_Medical"

Label   - "claimAmount"

 

This is what i had done, but  not working

 

 

 

 

Patch(
 employeeBalance,
 First(
 Filter(
 employeeBalance,
 Title = claimsEmail.Text
 )
 ),
 {Total_Medical:Sum(employeeBalance.Total_Medical, claimAmount.Text)};

)

 

 

 

 

 

Let's say if the user's current value in column Total_Medical is "20" and the claimAmount.Text ="20", it should update the column's value to "40".
Can someone please help me out? Thanks

Categories:
  • Verified answer
    v-qiaqi@microsoft.com Profile Picture
    Microsoft Employee on at

    Hi @Jesscy,

    Could you please tell me that:

    1. how you set the Text property of the claimAmount Label?
    2. do you have separate controls like Label and a button to save data? Is there a Gallery or a Form?
    3. Is the Title column a primary key in your "employeeBalance"?

    I just assume that you want to update the first record that meets the Filter() function.

    You should find out the corresponding Total_Medical value in the specific record as below:

    First(
     Filter(
     employeeBalance,
     Title = claimsEmail.Text
     ).Total_Medical

    Modify the formula 

    Patch(
     employeeBalance,
     First(
     Filter(
     employeeBalance,
     Title = claimsEmail.Text
     )
     ),
     {Total_Medical:Sum(First(Filter(employeeBalance,Title = claimsEmail.Text).Total_Medical, claimAmount.Text)}
    )

    Please check if the above could help.

    Regards,

    Qi

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