Link to home
Start Free TrialLog in
Avatar of diana_g
diana_gFlag for Canada

asked on

MS Access - Overlapping Sub Reports

Hello Experts,

I have a report that is contains 3 subreports, one after the other (see Report - Design View).  I created one subreport and then copied it to create the other two, only changing the Data Record Source and the Caption under Properties.

The subreports can vary in size (height) depending on the amount of data that needs to be displayed.  Typically, if a longer time period is selected, there will be more data for each subreport. (see Report - Good)  So, it should expand vertically and when it is finished, the next subreport should start.

I am experiencing an issue in that when I run the report, the third subreport always overlaps over the second (See Report - Error Overlap).  

Looking for some help as I do not understand why only the third report overlaps.  

Thank you for your help!
Report---Design-View.bmp
Report---Error-Overlap.bmp
Report---Good.bmp
Avatar of mbizup
mbizup
Flag of Kazakhstan image

Try scooting your third report down a bit.

In design view, it looks like it is barely touching/overlapping another control.

Give it plenty of space (exaggerated space) first, to see if that resolved the issue - and then fine tune it to get the spacing you want.
If you don't want any space between them, first provide some space, as mbizup suggests, then select the subreports with their captions and use “align top”. This will stack them without overlap and without spacing between them.

(°v°)
All three of the subreports (and the main Report) seem to have the exact same fields...?
Can I ask what this report actually displays?

If each subreport "filters" the data, (for example: sub1=USA, sub2=Germany, Sub3=Argentina) then you can try using the report wizard to create a "Grouped" report
AFAIK, it is impossible for "overlapping" to occur in a Grouped report.

You can also control the groups and where they page break a lot easier with a grouped report.
Finally you can easily add summaries for each group.

Just something else to consider if it is applicable...

(sample attached)
db33.mdb
Avatar of diana_g

ASKER

@mbizup - The 'spacing' needs to be flexible.  Depending on the amount of data, each subreport can vary in height.

@harfang - The align function works fine in Design View, but the overlap still occurs in Report View.

@boag2000 - Each subreport is actually a grouped report.

Although the field names are the same, the source data and tables for each subreport is different.  Example - Even though 'Mode' is displayed on each subreport, the 'Mode' source table for each subreport has different entries.  Same goes for Product.

I am still experiencing the overlap.  When I have two subreports, there is no overlap and they adjust accordingly based on the amount of data (i.e. more data, the longer each subreport).  But when I add in the third subreport, it continues to overlap over the second.
ASKER CERTIFIED SOLUTION
Avatar of Dale Fye
Dale Fye
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I never has this issue, except when the controls were already overlapping in design view.

I don't have other ideas at the moment, so just a sanity check: 1) All three subreport controls have “can grow: yes” (they can also safely use “can shrink: yes”). 2) The Detail section itself also has “can grow: yes” (and “can shrink: yes” if the subreports use it). 3) There are no other controls at the left, the right, or behind the subreports (separator lines, fossils from earlier designs, &c). 4) There is no code behind the main report or the subreport that resizes, moves, or hides controls or entire sections.

(°v°)
Avatar of diana_g

ASKER

Experts - Thank you for your help, but @fyed's second technique of creating groups with expressions worked great and there were no issues.
glad to help.

Actually, I think I learned that technique from boag2000, several years ago.
It is a good technique, for all sorts of problems. Here, it feels like a workaround, but the import thing is that it works! — (°v°)