Hello Chad,
If I understand the issue correctly, you may want to do the following:
goal goalprogress countofgoal
g1 s1 2
g1 s2 3
g2 s1 5
g2 s2 7
You 'd like to get following in report footer:
s1 total: 7(2+5)
s1 total: 10(3+7)
However, you actually have group on goal in the report and it's not
possible to get total of all rows with S1 or S2 status easily.
As far as I know, there is no simple method to achieve this goal. I think
there are 2 options:
1. Use a different report that is based on a query such as
select goalprogress sum(countgoal) from sourcetbl group by goalprogress
2. Use a query to get the information you want in report_open and save them
in global variables. Then you could show them in ReportFooter_Format by
using Me.textbox= var1
For example:
Private Sub Report_Open(Cancel As Integer)
Set db = DBEngine.Workspaces(0).Databases(0)
DoCmd.SetWarnings False
Dim rec As Recordset
Dim sString As String
sString = "select employeeid, sum(Freight) as fee from Orders group by
employeeid "
Set rec = db.OpenRecordset(sString)
i = rec.Fields(1).Value
End Sub
Private Sub ReportFooter_Format(Cancel As Integer, FormatCount As Integer)
Me.Text18 = i
End Sub
You may want to refer to the following articles for more related
information:
Q216311 - ACC2000: How to Create Page Totals on a Report
http://support.microsoft.com/support/kb/articles/q216/3/11.asp
841779 How to reset the page number and the total page count for each group
in a Microsoft Access report
http://support.microsoft.com/default.aspx?scid=kb;EN-US;841779
If you have any further questions or comments, please feel free to let's
know. Thank you.
Best Regards,
Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Partner Support
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
=====================================================
This posting is provided "AS IS" with no warranties, and confers no rights.