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

Group Formula 1

Status
Not open for further replies.
Your formulas are way too complicated.

The issue is that the first record has no previous() value. Change your formula to something like this:

Code:
WhilePrintingRecords;
If OnFirstRecord then numbervar GrpTot:={LIST_PO_DETAIL_BY_DATE.po_total}
else 
if LIST_PO_DETAIL_BY_DATE.po_code}=Previous ({LIST_PO_DETAIL_BY_DATE.po_code}) then Numbervar GrpTot:=GrpTot+{LIST_PO_DETAIL_BY_DATE.po_total}

Then create another formula to display the total, placed in the group footer:
Code:
WhilePrintingRecords;
Numbervar GrpTot;

Finally a formula to reset the variable to zero, placed in the group header:
Code:
WhilePrintingRecords;
If Not InRepeatedGroupHeader then Numbervar GrpTot:=0

I can't really test this but this should get you real close.

Software Sales, Training, Implementation and Support for Macola, eSynergy, and Crystal Reports

"What version of URGENT!!! are you using?
 
Hi,dgillz

I will try your suggestions and let you know the result.

Thanks for your advice
Ndaa
 
Using Crystal XI.

I have a report that is grouped to the 3rd level.
I have Page Header a and Page Header b.

The groups are suppressed for drill down from level 3 to the detail.

Page Header b shows when the report is first run at group 1 and then does not show when drilling down to the detail which is what I want.

Page Header a is currently suppressed, but I want it to show when the Drill Down gets to the Detail level.

Is there a way to not suppress Page Header a at the Detail Level?

Thanks,
Ray
 
Make sure that file->report options has "show all group headers on drilldown" checked. Then change your suppression on PH_a to a formula:

drilldowngrouplevel = 0

If you want it suppressed for the first and second drilldowns, change it to:

drilldowngrouplevel < 3

-LB
 
yankray,

PS. You should have started a new post.

-LB
 
LB -

I sent this incorrectly the first time and did not realize it so I started a new post correctly. I sent it but I am not sure what happed to it. Sent it again and still don't know. I will have to try and figure it out.

Thank you very much for answering it here. I thought I was out of luck.

Ray
 
Hi,dgillz

From your code,It's new style for me. So i am wondering how to coding for grouped the 1st,2nd level.I have 3 level grouping (supp/site/comp).
This mean that i will adding formula for group by site and comp in formula at detail section.

Thanks again for your help,
Ndaa
 
You would need additional variables to accumulate in the details section, you can use one formula for this. You would also need new formulas to reset the variables in the respective group headers, and display them in the respective group footers. Another accumulation variable and display would be needed for a grand total,but it would not be reset to zero. This is a classic 3 formula approach that is very common.

Software Sales, Training, Implementation and Support for Macola, eSynergy, and Crystal Reports

"What version of URGENT!!! are you using?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top