I have a subform in datasheet view displayed within a parent form. I want to sum a column and display the result in the parent form. Has anybody out there done this? Have come across a few explanations but I keep getting #name?
Thanks for any help.
I have a subform in datasheet view displayed within a parent form. I want to sum a column and display the result in the parent form. Has anybody out there done this? Have come across a few explanations but I keep getting #name?
Thanks for any help.
You have a textbox in the subform form footer section with Sum(fieldname)?
You have a textbox on main form that references the subform textbox?
Post the expression from the main form textbox.
Suggest naming the subform container different from the object it holds, like ctrDetails.
Then reference the subform textbox like:
=[ctrDetails].Form.[textboxname]
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
Ok thanks think I get it. Will try and report back. :-)
Thank you that worked perfectly, I had wrong syntax which I got elsewhere. Goes to show stick to this forum..
Thanks again.
Just before this one is closed. I am trying to get a running total of the sum in the previous post. But keep getting an error.
Not easy in query and form. Requires nested subquery or DSum() expression.
Textbox on report has RunningSum property.
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
Ah Ok sounds a bit beyond me. Maybe just do without until I get used to Access etc.
Thanks again.