Summing Value in Header row

D

Don

How do you sum a value that is placed in a header section. For example, the
data being returned to the report looks like this (3 Rows).

Salesperson Customer Product ProductCost SoftCost
Steve A 1 $2,000 $500
Steve A 2 $5,000 $500
Steve B 3 $4,000 $450

The first Header is for the Salesperson, the second is for the Customer and
the Detail is at the product. The Soft Costs are at the Customer level and
don't get broke up by Product.

The report would look like this
----------------------------------------------------------------------
Salesperson Steve (Header 1)
Customer A SoftCost = $500 (Header 2)
Product 1 $2,000 (Detail Line)
Product 2 $5,000
Customer B SoftCost = $450
Product 3 $4,000

Salesperson Footer ProductCost Total = $11,000 SoftCost Total = $950
----------------------------------------------------------------------
For the Product total I do =sum(ProductCost), but doing =sum(SoftCost) would
give me $1450. I tried renaming the control in the header to txtSoftCost and
doing =sum(txtSoftCost) but that gave me an error.

Thanks

Don
 
D

Duane Hookom

How about the same answer I gave you in Tek-Tips:
Add a text box to the Salesperson group header:
Name: txtSoftCostRS
Control Source: SoftCost
Running Sum: Over All
Visible: No
Add a text box to the Report Footer:
Control Source: =txtSoftCostRS
 

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

Top