cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ericonline
Community Champion
Community Champion

Sum hours in "##:##" format in a Collection Column

Hello, 


I'm having trouble here hope someone can assist. 

 

I'm trying to sum an hours column in a Collection. The Collection has a column (duration) with values such as "02:00" (two hours) and "05:30" (five hours, thirty minutes). I want to sum these columns.

 

I'm using a Textbox control with its Default property set to: 

Text(
    Sum(
        workSummary,
        duration),
    "[$-en-US]##:##"
)

I have no errors showing in the Text box, but no values appear when the collection is populated with hours. What am I missing here? 

 

Thanks

 

10 REPLIES 10

@v-xida-msft wow! I've been dissecting this code for a while on the whiteboard.... this is really smart stuff. Great work again! Wish I could double-Kudo!

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

Power Apps Community Call

Monthly Power Apps Community Call

Did you miss the call?? Check out the Power Apps Community Call here!

Power Platform ISV STudio

Power Platform ISV Studio

ISV Studio is the go-to Power Platform destination for ISV’s to monitor & manage applications post-AppSource publish.

Top Solution Authors
Top Kudoed Authors
Users online (74,129)