Group Problem

S

Shell

I made a report in four group levels. If there is no data in the second group
or third group, there is an empty area in the report. It made report looks
bad.
 
W

Wayne-I-M

Hi

Set the detail and group headers (and all text boxes in them) to can shrink
= yes and Can grow = Yes.

Don't use lables as these will show even if there is no data in the detail
section. Although you could code these not to, it's simpler just not to use
them.
 
S

Shell

I have set as following:
Grow=yes; shrink=yes
But the result is the same. Would you please give us some code samples to
solve this problem
 
W

Wayne-I-M

You don't need any "code"

I can't see your report so please bare with me. On your report you should
have the sorting and grouping set for the items your have in your report. If
you have selected yes for group header and footer you will prob have a text
box containing the group title in the header and in the footer any sums and
other info. In the details section you will have the items themself.

Open the report in design view
Right Click the Header line (it's a think line above the header section) and
select Can grow = Yes and Can Shrink = Yes
Do the same for the footer

This should do the trick.

If it doesn't it means that there is siomething in these section that isn't
shrinking so you need to find out what it is and apply the can shrink to it.
 
S

Shell

My report is as following:
Group1: 1ChildPN;1MaterialUsage
Group2: 2ChildPN; 2MaterialUsage
Group3: 3ChildPN;3MaterialUsage
Group4: 4ChildPN; 4MaterialUsage
When I set all text box as following: Grow=yes; Shrink=yes
The result as following:
1ChildPN
1MaterialUsage
2ChildPN
2MaterialUsage
3ChildPN
3MaterialUsage
4ChildPN
4MaterialUsage

I don't know what's wrong with it.
 
W

Wayne-I-M

Don't really know what you have done here.

I assume you have a field in your table called MaterialUsage and you are
sorting the report on that. If this is the only name of the field then
delete the other grouping options.

What are
1MaterialUsage 2MaterialUsage 3MaterialUsage 4MaterialUsage
If they are field names then they will group as sub groups of each other

You will have
1MaterialUsage details
Any details that are grouped within 1MaterialUsage "and" 2MaterialUsage

If they are "not" field names I would suggest that you copy the report and
on the copy delete all the groups for 2MaterialUsage 3MaterialUsage
4MaterialUsage
 
S

Shell

Done

Wayne-I-M said:
Don't really know what you have done here.

I assume you have a field in your table called MaterialUsage and you are
sorting the report on that. If this is the only name of the field then
delete the other grouping options.

What are
1MaterialUsage 2MaterialUsage 3MaterialUsage 4MaterialUsage
If they are field names then they will group as sub groups of each other

You will have
1MaterialUsage details
Any details that are grouped within 1MaterialUsage "and" 2MaterialUsage

If they are "not" field names I would suggest that you copy the report and
on the copy delete all the groups for 2MaterialUsage 3MaterialUsage
4MaterialUsage
 
W

Wayne-I-M

Well done.

Just one point to remember - you can't just invent names in reports, codes,
moduals, etc.

Any field or control names you refer to MUST be as stated in the base table,
form (if you have renamed a control), report or query - this doesn't mean you
can't refer to unbound fields on a form in the forms code - you can of
course. BUT when refering to Bound controls or fields the name MUST be
exactley what you have given them.
 
Top