Is there a way of calculating the sub totals of each repeating section? I am trying to construct an invoicing form for our freelance workers. The repeating sections are very useful so that only the relevant parts are viewable to the form filler, but although I can create an invoice sub total for each section, I cannot find a way to calculate an invoice total at the end.

Do you have any suggestions?

1 Answer 1


There are a couple of ways to handle calculating subtotals for repeating sections:

  1. If the form represents a true invoice and the subtotals represent money and nothing else, you can set the form up to use the built in payment features of Cognito Forms. When you mark fields as Collect Payment, they will automatically appear on receipt/invoice grouped by repeating section item. Choice, Currency, Yes/No and Price fields can all appear on this "invoice" and the Price field gives you complete control with the ability to calculate both the amounts and the description of each line item if you need this power. In this case you would not be collecting payment from them, so mark the form via Payment Settings as never requiring payment.

enter image description here

  1. The other option is to use the powerful calculation capabilities in Cognito Forms to quickly calculate the subtotals. In the example above, you could add a Calculation field at the bottom of the form and use a calculation like =MyOrder.Sum(ItemTotal) or even =MyOrder.Sum(Product_Amount * Quantity) to calculate the total for the My Order repeating section. Remember set the Type to Currency for the Calculation field so it will be formatted correctly and allow you to use the value of this field in other calculations. You can learn more about these capabilities in our help documentation at: https://www.cognitoforms.com/support/51/calculations/repeating-sectionstables. Take a look at the section on Working with Repeating Sections.

Please mark this as the answer if it helps you make this work, or add a comment if it is not quite what you were looking for.

  • Thanks for your answer. I don't seem to have any payment options, though. Do I need to add a payment account to access these?
    – Charlie
    Mar 9, 2015 at 14:09
  • I've looked into it and the first option wouldn't be suitable. Option 2 is the one I am looking for but cannot get the calculation to work.
    – Charlie
    Mar 9, 2015 at 14:21
  • Please edit your question to provide concrete examples, possibly with a screenshot. Also, your summary calculation fields will need to be top-level (not inside a section). Mar 9, 2015 at 14:37
  • Hi Jamie, thanks for your suggestions but this is all too technical for me! I don't know how to add images to my original comment. What does summary calculation fields and top level mean? There are 6 different sections freelancers can select from for the different types of work they can complete for us. Within each section I've put a subtotal. What I'm trying to do is calculate all the sub totals from the different sections at the end... Hope that helps make it clearer! Thanks for your help so far.
    – Charlie
    Mar 9, 2015 at 15:33
  • No problem, you are new to both Stack Exchange and Cognito Forms, so I will do my best to help you with both. Would you please submit a bug report to us (bottom of the Support page) so I can see which forms you are working on, and I will update your question for you here and my answer as well. Mar 9, 2015 at 16:27

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.