Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: supressing a group Post Reply Post New Topic
Author Message
dkalsow
Groupie
Groupie
Avatar

Joined: 10 Jan 2011
Location: United States
Online Status: Offline
Posts: 65
Quote dkalsow Replybullet Topic: supressing a group
     Posted: 25 May 2011 at 5:50am
Good Morning,
 
I need to supress the group if the number of detail lines in it are not greater than one.  Has anyone every done anything like this before?
 
 
Thanks :)
dkalsow
IP IP Logged
dkalsow
Groupie
Groupie
Avatar

Joined: 10 Jan 2011
Location: United States
Online Status: Offline
Posts: 65
Quote dkalsow Replybullet Posted: 26 May 2011 at 10:17am
I ended up reading all the lines for the goup into an array and then in the group footer checking to see the number of used lines in the array.  If they are were greater then one, I then printed them on different group footer lines out of the array.
 
 
Thanks :)
dkalsow
IP IP Logged
Dewald
Groupie
Groupie
Avatar

Joined: 02 Jun 2011
Location: South Africa
Online Status: Offline
Posts: 47
Quote Dewald Replybullet Posted: 02 Jun 2011 at 5:41am
I have not tried this, but theoretically you could do a running rotal that counts the detail records by the grouping record.
 
Then base the surpression on this.
 
This should work as running totals gets calculated before grouping is done.
 
 
Dewald Botha
http://www.ITClarity.co.za
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 02 Jun 2011 at 6:16am
I don't think the RT would work but an "insert summary" (of a count of any field that exists on each row reset at teh group level) would.
You can also use it to exclude the groups from the report canvas (not the report tree though) using it in group select expert ...
Count(field,Group)<2
IP IP Logged
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum