Picking up Sub form totals from a main form

Jd963

New member
Local time
Today, 03:47
Joined
Mar 22, 2013
Messages
5
I have converted an old Access 97 database to Access 2010. Mostly it works fine but I have a major issue with the invoicing forms. It was working in the old database but I cannot get it to work in this version.
I have the usual invoicing option where the lines of the invoice are displayed in a sub form for that customer and line totals calculated. This works fine. I have a sub form total text box in the footer of the sub form which I want to pick up from the main form so that I can add the delivery charge and VAT.
I have looked at all the forum posts (this one and others) for this as it seems to be a recurring theme! I am doing all the methods that are described and was doing them anyway before it stopped working. The text box on the main form is set up using the expression builder to pick up the sub form total text box value. It does not display anything at all. I have exhausted my abilities here and don't know what to do now. This is vital for the customer as his business depends on being able to produce his invoices. I have recreated the invoicing main form and subform as that sometimes works if there is a problem but not in this case, sadly. The auto number field for new invoices is also not working as t is using the last used number for that customer. Very frustrating. I have used Access for a number of years and created the original database but I am not a programmer. I can take code and change names etc but that's about it.
Any ideas anyone? I'm at my wits end with this now. Is there something major that changed in 2010 that might be causing this problem?
 
In the date source of a textbox on your main form:

=[SubformName]![SubformTextBoxName]

should give you the value of the textbox you want to capture
which in your case is the sub-total.
 
I have done this over and over again, deleting it, typing it in myself and also using the expression builder to do it. I have checked again and again that it is the correct syntax and has the correct names in etc. Not working though. :banghead:
 
I have done this over and over again, deleting it, typing it in myself and also using the expression builder to do it. I have checked again and again that it is the correct syntax and has the correct names in etc. Not working though. :banghead:
Check out my tutorial here. It can help you get exactly the right thing for your use.
http://www.btabdevelopment.com/ts/refer2sfrms
 
Thanks for your answers so far. I have been doing all this for years and it was working in this database before I transferred it into 2010. I am really struggling with this and am about to throw the computer out of the window!
I need some serious help now and I think I may have to find another consultant who knows about Access to help so we can sit down with it together but don't know where to start. :(
 
Have you actually confirmed that the totals in the Control, in the Footer of the Subform, is working properly? Common mistakes in doing this sort of thing include
  • Trying to use SUM against Control Names
  • The Expression using SUM has to be done using the Field Names, not the name of the Textboxes on the Form.
  • Trying to SUM a Calculated Field
  • You cannot SUM against a Calculated Field, you have to SUM the expression itself
If

C = A + B

you cannot use

=SUM(C)

you have to use

= SUM(A + B)

Linq ;0)>
 

Users who are viewing this thread

Back
Top Bottom