cancel
Showing results for 
Search instead for 
Did you mean: 

Repeating Tables

It would be great to have a repeating table control like in Infopath so that users can add multiple entries and submit them altogether. Also we should be able to do calculations based on rows , for example if I'm adding 3 expenses, I should be able to calculate the total and etc. 

This nothing new but an exisitng feature in Infopath. 

Status: Started

Thank you for your feedback! Much work is being done to facilitate form based controls. We will keep you updated as the work progresses.

 

In the meantime, you should already be able to sum rows. Please see article links below which should address requirement example (sum of expenses).

 

reference:

https://powerapps.microsoft.com/en-us/tutorials/working-with-tables/

 

webinar on formulas including a sample of your example:

https://info.microsoft.com/US-EAD-WBNR-FY17-03Mar-14-GettingStartedwithPowerAppsFormulas300770_01Reg...

 

Thank you,

Audrie

Comments
Level 10

Hi afernando, most of what you propose is already possible.

 

For a repeating table you can use a gallery.

 

In order to edit multiple entries you simply add a text input to the gallery, then you can for example update each item as its input box is changed.  If you want to submit them all together then you can store the changes in a collection instead and then have a button to submit all changes stored in the collection.

 

Calculations based on rows are even simpler, use the Sum function in this way:

Sum(Gallery1.AllItems, ExpenseAmount)

 

If you want to sum only those items you select then you can add a check box control to the gallery and on select/deselect add the number you need to a context variable for example.  Another idea is to use a list box instead (which makes multiple selections possible out-of-the-box) and use this:

Sum(ListBox1.SelectedItems, ExpenseAmount)

 

Please let me know if you need more details, but probably more appropriate in the forum. 

Level 10

Hi Steelman70,

 

Thanks for your reply.

 

Can you please elaborate on the following?

"If you want to submit them all together then you can store the changes in a collection instead and then have a button to submit all changes stored in the collection."

 

How can I achieve this in an app bound to SharePoint Online? Thanks in Advance.

 

Afernando

Level 10

Hi afernando, sorry I cannot test today but it should work something like this:

 

In your gallery item add a yes/no checkbox control.

 

For the OnChange property of the checkbox you can have a pseudocode like this:

If(MyCheckBox = true, Collect(MyChanges, {RecordID: Gallery.Selected.ID, Field1: NewValue1 etc. etc.}), RemoveIf(MyChanges, RecordID = Gallery.Seleced.ID))

Then you have a button outside the gallery where the OnSelect can be:

Collect(MyDataSOurce, MyChanges)

Please let me know how you get on.

Level 10

Hi Afernando

 

For submitting all the data in the Collection, it needs to be collected and patch one at a time. This is what I have done in the forum...AUTOSAVING in Batch.

 

Please view this link:

 

https://powerusers.microsoft.com/t5/PowerApps-Forum/Useful-Features-of-PowerApps-12-AutoSaving-of-Ba...

 

Hope this helps.

Flow Staff
Status changed to: Started

Thank you for your feedback! Much work is being done to facilitate form based controls. We will keep you updated as the work progresses.

 

In the meantime, you should already be able to sum rows. Please see article links below which should address requirement example (sum of expenses).

 

reference:

https://powerapps.microsoft.com/en-us/tutorials/working-with-tables/

 

webinar on formulas including a sample of your example:

https://info.microsoft.com/US-EAD-WBNR-FY17-03Mar-14-GettingStartedwithPowerAppsFormulas300770_01Reg...

 

Thank you,

Audrie

Level: Powered On

Look to MS Access for how simple this should be.

With Access you can create a form and subform on two connected tables. We should be able to do this via two data sources by specifying the parent/child relashionship via a simple GUI drag and drop.

 

I know this can currently be achieved - but I think it's out of most people's grasp. If there were a more visual way to get this type of form set up it would be a great help for many use cases. 

Level: Powered On

As an option, you can look into market solutions, there are apps that allow you to build forms with tables, including all the calculations that you might need, then submit data to Flow and add/update items in Common Data Service, SharePoint or SQL server.

 

Here's an example of what I am talking about - https://medium.com/plumsail/public-web-form-with-repeating-rows-to-sharepoint-items-with-ms-flow-b2e...

 

There could be other solutions as well. Perhaps it will be possible with Powerapps soon too, but it can be an option right now.

Level 10

Here is how to implement editable repeating sections:

https://baizini-it.com/blog/index.php/2018/02/08/powerapps-repeating-section/

Level: Powered On

Any news about this statut?

Level: Powered On

any news?