Basically i have several subforms on a page (continuous forms) and they all have a simple sum function in a text box. sum=([quantity]).
I now want to add all the totals and display them on the page in a text box...
In the unbound text box that is to hold all the totals you should be able to add the following as the control source, substituting for the subform name and each control's name as appropriate:
- =Me![subformname].form![ControlTotalName1] + Me![subformname].form![ControlTotalName2] + ...
This simply adds the values in each of the specified controls; if one of them is null this would fail. If a null value is at all likely then use the Nz function accordingly:
- =Nz(Me![subformname].form![ControlTotalName1],0) + Nz(Me![subformname].form![ControlTotalName2],0) + ...
I assume that your reference to the totals formula for your subform controls as
sum=([quantity]) is just a typo, and that you meant
=sum([quantity]) instead.
-Stewart