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!

Formula to keep together 1

Status
Not open for further replies.

mr2tho

Programmer
Mar 30, 2006
25
US
Crystal 9.0. I have three groups.
If I go to Section Expert, "Keep together" is checked for all of them.

When I go to Group Expert, click on options, Check "Keep Group Together" then it's sometimes trying to put the whole group in a new page causing lot of half full pages...

Okay What I am trying to do:
For My second Group I already have "Keep Group Together" checked and I am happy about it. But the heading belonging to that which is Group1 is ususally at the end of page right before that page. I wish at least the Group1 heading would go to second page.

I am sure you undertood but just to make it clear, this is what happens when I turn "Keep group together" for group 1

Page X:
Half Empty

Page X+1:
Group1 Heading
Group2 Heading-1
Records
Group2 Heading-2
Records
Group3 Heading-3
-----
And I am wondering if it's possible to have
Page X
Group1 Heading
Group2 Heading-1

Page X+1
Group2 Heading-2

Just to do this I only put Keep Group Together for Group2. In that case, for other records then I had lots of Heading1 at the end of the pages, and Group2 Headings at the very peginning of the next page.

Any solution just not to have my Group1 heading at the end of the page?
Thanks
 
Right click the group and select change group and in to options select repeat group on each page, perhaps that's what you want?

-k
 
You know that kind a fixed it but in a little lousy way. I loved everything except the same heading is now at the end of the page as well as the beginning of the next page.

I did have the heading on the next page though, I give you credit. Thanks

Is there any other way or a way to get rid of the extra heading at the end of the page for some group headings?
 
Good morning and thanks synapsevampire,

It really is not important but putting a New page would give me lot of half full pages, worse than having a keepgrouptogether on group1.

My main purpose was to see if you people already apply some tricks for this kind of formating problems beause I am impressed with the tricks that Lbass knows. He uses the formulas in the most expert way. So in conclusion, I am learning Crystal Reports. And now that you and other people looked at it, I know that it's not much I can learn about this kind of data dependent problem. And I will try to ask on more important topics.
Thanks for your input.

Note:
I looked at Lynda.com for some crystal reports training but the training I watched was extremely simple (3 CD), it was disappointing for me, unfortunately I didn't learn a single extra thing, only killed a lot of time...We need advance Crystal Reports training.
 
One approach would be to insert another Group#2 header section and drag it so that it is GH#2a. Drag your Group #1 groupname into this section and then go to the section expert->GH2a->suppress (do not check this)->x+2 and enter:

{table.group#1field} = previous({table.group#1field})

Then suppress the group #1 header.

-LB
 
Perfect, perfect, perfect...Welcome to the tricks of Crystal Reports. If you have training classes, I'll be in your class. Thanks.
 
Is it possible to do the same thing for the group1 footer to have the totals in group footer1 (which is just one line) to print in the same page as group2?
 
It depends upon your summaries. You can insert another group #2 footer, but if you move inserted summaries to the group #2 footer, they will take on the group #2 value for that summary, so you would have to replace them with formulas like:

sum({table.amt},{table.group#1field})

An inserted running total should display correctly. Anyway, check to make sure the values are correct. To suppress the group #2 footer, you would use a section suppression formula of:

{table.group#1field} = next({table.group#1field})

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top