Hi, this is a forgotten question still in need of an answer
I want a group delimited as below with sums:
InfrastructureServices 80
IS-ext 50
detail1 20
detail2 20
detail3 10
IS-int 30
detail1 10
detail2 20
ManagedServices 120
MS-ext 90
detail1 90
MS-int 30
detail1 20
detail2 10
The red 'groups' are sums of the dark blue 'groups' which are in turn sums of the details. It needs to be formatted like this. Is this possible?
I've tried all sorts of ways. I tried summing in the details but this raised an error. I'm using global variables to hold the summary values but where are they summed?
This is what I'm using to sum it:
Global NumberVar ISSum1;
Global NumberVar MSSum1;
Global NumberVar MCSum1;
if GroupName ({ResourceUsageReport.OrganizationName}) = "Infrastructure Services"
then
if Left(({ResourceUsageReport.OrganizationName}),2) = "IS"
then
ISSum1 := ISSum1 + ( Sum ({ResourceUsageReport.Period1}, {ResourceUsageReport.OrganizationName})
/ sum(
{@AvailWkHrs1},{ResourceUsageReport.OrganizationName})*100 )
else if GroupName ({ResourceUsageReport.OrganizationName}) = "Managed Services"
then
if Left(({ResourceUsageReport.OrganizationName}),2) = "MS"
then
MSSum1 := MSSum1 + (Sum ({ResourceUsageReport.Period1}, {ResourceUsageReport.OrganizationName})
/ sum(
{@AvailWkHrs1},{ResourceUsageReport.OrganizationName})*100 )
.
.
.
.
else
Where does this go? If I put it in the details, it throws an error so I put it on the footer but it returns no results for Infra...., Manag....., only the small IS, MS type groups.
This is what I'm using to determine which global variable to display. I'm putting this in the group header:
Global NumberVar ISSum1;
Global NumberVar MSSum1;
Global NumberVar MCSum1;
if GroupName ({ResourceUsageReport.OrganizationName}) = "Infrastructure Services"
then
ISSum1
else if GroupName ({ResourceUsageReport.OrganizationName}) = "Managed Services"
then
MSSum1
else if GroupName ({ResourceUsageReport.OrganizationName}) = "Management Consulting"
then
MCSum1
else
The above formula returns zero for all conditions except 'else'.
@AvailWkHrs1 is from the header & is this:
round({ResourceUsageReportHeader.WorkHours1}/8)*8
I've been trying to work this out for weeks. Any ideas on how to do this would be most appreciated!
Many thanks
Ant
Edited by TokyoAnt - 13 Mar 2007 at 2:51am