retriving a calculation from a sub-from

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

My main form is called "Master". My sub-form is called "Record Detail". The
link field is PO#. . =sum([Weight]) works on the subform, however, how
would I get the calculation from the subform to appear on the Master form.
 
put a control in your main form and have its control referred to the control
in your subform that computes the weight.

sample: Forms!Master![Record Detail].form![Name of your control]


ZAQYU
 
Create a Sum field in the sub form as you indicated.
Create a Field in the main form and in the control source of that field write

=[Record Detail].Form![Sum field in the subform]

if the [Record Detail] is also the name of the sub form control within the
main form
 
If the sum is showing in a text box named Text0 in the subform, use this:
=[NameOfYourSubformControlHere].Form!Text0

For an explanation, see:
Referring to Controls on a Subform
at:
http://allenbrowne.com/casu-04.html

For an example, open the Northwind sample database that comes with Access,
and see how the Orders form picks up the total from the subform.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top