Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Calcul;ating in A report 1

Status
Not open for further replies.

Cillies

Technical User
Feb 7, 2003
112
GB
Hi, I have a report with a grand total at the bottom. No problem here, but I want to omit a particular company from the grand total each time the report is run. but at the same time I need to display the figures for that company, I just don't want them in the grand total.

Hope someone can help.

Kindest Reagrds
Cillies.

p.s
each company has a range of projects i.e.
CompanyName: xzy
ProjectName: a
ProjectName: b
ProjectName: c
etc.
 
Have the control source of your toatals box as
=Sum(IIf([companyfieldname]="companyname",0,[valuefieldname]))

If that makes sense.

Eddie
 
I not that sure!

Companyfieldname = the name of the field where the company name is stored i.e. CompanyName

companyname = is the actual name of the company i.e xyz

valuefieldname = the project name i.e ProjectName

 
Yep thats right, but can you show me the control source for your grand total at present and I'll get it right.
 
Sorry! Its OK!
I was a bit silly there.
That works fine thanks for your help.

Kindest regards Cillies
 
Sorry to bother you again but I am trying to return a percentage of two of the grand total fields, but I keep getting the wromg value back.
below is the two control sources and my attempt at solving the problem.

=Sum(IIf([CompanyName]="IMM",0,[SumOfProjectStartup]))
=Sum(IIf([CompanyName]="IMM",0,[SumOfSumOfStartUpHours]))

My Attempt

=(IIf([CompanyName]="IMM",0,([SumOfProjectStartup]/[SumOfSumOfStartUpHours])))

This returns the value of the last entery on the list.

I'm trying to take the total of [SumOfProjectStartup]and divide it with the total of [SumOfSumOfStartUpHours]
 
Again I've jumped the gun!

Sorted it.

My head doesn't seam to have switched on yet
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top