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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Can I put groups into my report footer?

Status
Not open for further replies.

peterswan

Programmer
Sep 25, 2002
263
US
Hello,

I'm doing a report on the productivity of all of our company copiers by month. Each machine is listed as a group, and each month is a sub group of the machines.

At the end of the report I'd like to put how ALL the machines did for each month. I'm trying to add a group by month for the report footer but it doesn't seem to let me.

Is this possible?

thanx for any response.

Peter Swanson
 
You have three options: use a crosstab with the month as the row and whatever you are using to measure productivity as the summary field, insert a subreport into the report footer and just group by month, or just use a chart and graph by month.
 
so in other words you want the monthly productivity for all machines as a report footer summary.

That isn't too bad...we can do it without you having to rewrite your current report.

In the report header create the following intialize formula

******************************************************
@initialize (suppress in Report header)

WhilePrintingRecords;
NumberVar array MonthlyTotal := [0,0,0,0,0,0,0,0,0,0,0,0];
//add this since the result of a formula cannot be an array
" ";
*******************************************************

Now in the detail section create the following formula

*******************************************************
@TotalMonthlyProductivity (suppress in detail section)

WhilePrintingRecords;
NumberVar array MonthlyTotal;

//I am going to assume your month is based on some
//date value...you can modify accordingly to get a
//numeric month value

MonthlyTotal[Month({Table.date})] :=
MonthlyTotal[Month({Table.date})] +
{Table.ProductivityValue};

********************************************************

Now you just have to create the look you want in the Report footer.

An example of a display formula might be
******************************************************
@Display_JanuaryTotals (NOT suppressed in the report footer)

WhilePrintingRecords;
NumberVar array MonthlyTotal;

"Total Productivity for January: " +
totext(MonthlyTotal[1],0);

********************************************

Obviously the display formula can be more complicated, but I think you get the idea.

Hope this helps Jim Broadbent
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top