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!

Suppressing group header based upon summarized footer

Status
Not open for further replies.

anglophobe

Technical User
Nov 27, 2006
11
CA
I need to suppress a group header based upon a summarized value in the group footer.

My set up is like this:
GH1: CreatedDateTime
Details ID# @Time_In_Status @SumTimeToEnd
GF1: @Ave_Time_In_Status_Week

the Time_In_Status formula gives a simple number value.
The SumTimeToEnd formula is
Code:
whileprintingrecords;
if {@Time_In_Status} > 0 then
numbervar counter_week := counter_week + 1;
numbervar total_week := total_week + {@Time_In_Status};
The Ave_TimeToEnd formula is
Code:
whileprintingrecords;
numbervar counter_week;
numbervar total_week;
If {@Counter_week} <> 0 then
({@Total_week} / {@Counter_week})

currently, the group footer is suppressed with this:
Code:
If {@Ave_Time_In_Status_Week} = 0 then
true
I cannot use the same code to suppress the header, as the number I get for the @Ave_Time_In_Status_Week is from the previous week.
Any suggestions on how to suppress the header?
I am using CR10
 
Rather than dictating architecture and the formulas to be used, consider requesting architectural assistance by providing example data and the expected output.

You reference a formula called: {@Ave_Time_In_Status_Week}, but show code for other formulas, we don't know what is in there, and it won't work that way anyway, your formula is evaluating after the group header. And we don't know what is in: {@Time_In_Status}

Not sure why you prefer this sort of post, it's only going to result in questions, please try to supply basic technical inforamtion and requirements, then if you're compelled, you can state what doesn't work.

Since you need something in the group header, you're going to have to use a different way to get an aggregate, or use a subquery or subreport.

-k



 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top