cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Helper II
Helper II

Calculated fields in Excel (OneDrive) not updating when patching from PowerApps

Hello everyone,

 

I have a table as a data source in Excel (OneDrive), let's call it Table1, and I'm trying to patch new registers from PowerApps using data coming from a form.

 

Table1 looks like this:

 

Name                               Quantity                                     Cost                       Total                   Status

Daniel Surname2$30,000$60,000Approved
Maria Surname3$35,000$105,000On-hold

 

Where Total is the result of Quantity * Cost (via Excel formula).

 

In PowerApps, users fill in data for Name, Quantity, Cost and Status and push a button that patches it to the Excel table:

 

Patch(DataSource; Defaults(DataSource); {Name: Name_TextInput.Text; Quantity: Quantity_TextInput.Text; Cost: Value(Cost_TextInput.Text); Status: Status_TextInput.Text})

So far I've been able to collect the data and add it to Table1. However, the calculated column Total is missing all the values (not just the one from the newly created record).

 

Problem 1: The Total value is not being calculated for the newly created register. Is there a way to keep the calculated column other than patching also the calculated value?

Problem 2: The Total value for the existing registers is getting deleted in the data source, not in the table I have in PowerApps. Is there a way to prevent this?

 

Thank you in advance for the help!

 

P.S: PowerApps formula might differ a bit if you're not using the European version. Probably only the semicolons instead of commas.

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support
Community Support

Hi @PowerAppsDaniel ,

 

It is known that if the excel table contains calculated value, then the existing records won't show in PowerApps. 

 

But you should be able to add new records to excel table using PowerApps. And you can set below formula in the Default property of the textinput control in Total data card to achieve the calculation.

 

DataCardValue1.Text * DataCardValue2.Text

 

Regards,

Mona

Community Support Team _ Mona Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
Community Support
Community Support

Hi @PowerAppsDaniel ,

 

It is known that if the excel table contains calculated value, then the existing records won't show in PowerApps. 

 

But you should be able to add new records to excel table using PowerApps. And you can set below formula in the Default property of the textinput control in Total data card to achieve the calculation.

 

DataCardValue1.Text * DataCardValue2.Text

 

Regards,

Mona

Community Support Team _ Mona Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

News & Announcements

Community Blog

Stay up tp date on the latest blogs and activities in the community News & Announcements.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Community Highlights

Community Highlights

Check out the Power Platform Community Highlights

Top Solution Authors
Top Kudoed Authors
Users online (11,274)