Solved

Subform Total shows #Error

Posted on 2015-02-11
3
209 Views
Last Modified: 2015-02-16
In MS Access 2010 I have Main form frmMain and subform frmSubMain.
Both forms are not bound forms.
On subform  frmSubMain I have a  several fields one of them is field : “Amount”  this field  I want to summarize.

 All fields on subform showing proper values and that is ok and I can see  Amounts value too .
I put in subform frmSubMain footer  text field txtTotAmount and  formatted it as currency and here I went through Expression Builder and find the field Amount in subform  frmSubMain and put it in, so in field I have : =Sum([Amount]).
It worked before, and I was getting proper amount total value,  I do not remember changing something,  but now I am getting in the txtTotAmount  field value    “ #error “ I tried with  =NZ(Sum(Amount)) but it not worked.
0
Comment
Question by:Taras
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 47

Expert Comment

by:Dale Fye (Access MVP)
ID: 40603834
If you want to a control to display a sum, you need to:

1.  use the DSUM( ) domain function to define what column you want to sum, from which table, and under what criteria.

2.  in a bound, continuous form, you could put a control in the footer (txt_SumAmount) of the form and set its control source to:

= SUM([Amount])

If you want to display this sum on the main form, you would hide the footer of the subform, and set the ControlSource of the control on the main form to something like:

= Forms!MainFormName.subFormControlName.Form.txt_SumAmount
0
 

Accepted Solution

by:
Taras earned 0 total points
ID: 40603883
I apologize,  I said subform is not bound  I was wrong . Actually Record Source of subform is Query:  “ QryQueryOne”.
So it means subform  frmSubMain is bound to that query.
0
 

Author Closing Comment

by:Taras
ID: 40611878
Thanks a lot.
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

It’s been over a month into 2017, and there is already a sophisticated Gmail phishing email making it rounds. New techniques and tactics, have given hackers a way to authentically impersonate your contacts.How it Works The attack works by targeti…
This article describes two methods for creating a combo box that can be used to add new items to the row source -- one for simple lookup tables, and one for a more complex row source where the new item needs data for several fields.
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question