473,800 Members | 2,930 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Multiple page subreport cuts off in report header

21 New Member
Hello,
I have a report with a subreport in its header. When I run the subreport by itself, it shows multiple pages, correctly. When I view the main report, the subreport prints to the bottom of the first page and does not go on to display the rest of its records - the records of the main report begin on the second page. I have tried setting the CanGrow property of everything to "yes" and experimented with lots of the other properties. Does anyone know what might be causing this?

Thanks,
Whitney
Nov 7 '06 #1
10 3999
MMcCarthy
14,534 Recognized Expert Moderator MVP
Hello,
I have a report with a subreport in its header. When I run the subreport by itself, it shows multiple pages, correctly. When I view the main report, the subreport prints to the bottom of the first page and does not go on to display the rest of its records - the records of the main report begin on the second page. I have tried setting the CanGrow property of everything to "yes" and experimented with lots of the other properties. Does anyone know what might be causing this?

Thanks,
Whitney
Why is the subreport in the report header

What field is in common between the header section and the subreport?
Nov 7 '06 #2
wjfraser
21 New Member
Why is the subreport in the report header

What field is in common between the header section and the subreport?
The report is a list of projects. The subreport is a list of bios for all staff who have worked on the projects, so it needs to occur just once, at the beginning of the report. After a bit more experimentation , it looks like the subreport is only displaying the first record (no matter how short or long the bio is - so, even if there is space left on the page, it won't display any more records BUT if the first record is more than a page long, the one record runs quite nicely onto the next page).

The flow of this project is:
User selects one or more staff members, and some key words.
Report displays all projects that the staff member has worked on by filtering the keyword query by the "ProjectSta ff" field (this part works just fine).
There is a SELECT DISTINCT query on [ProjectStaff] that feeds into the subreport.

Thanks for any help.
Nov 8 '06 #3
MMcCarthy
14,534 Recognized Expert Moderator MVP
There is a SELECT DISTINCT query on [ProjectStaff] that feeds into the subreport.
What is the master/child or filter relationship between the Group Header which I assume is based on ProjectStaff and the subreport?
Nov 9 '06 #4
wjfraser
21 New Member
What is the master/child or filter relationship between the Group Header which I assume is based on ProjectStaff and the subreport?
Yes, the Group Header is based on ProjectStaff, but I don't think the grouping has a direct relationship with the subreport.

When I look at the subform properties, I see
Link Child Fields......Pro jectStaff
Link Master Fields...Projec tStaff

Is there another place to look for master/child relationships?
Nov 9 '06 #5
MMcCarthy
14,534 Recognized Expert Moderator MVP
Yes, the Group Header is based on ProjectStaff, but I don't think the grouping has a direct relationship with the subreport.

When I look at the subform properties, I see
Link Child Fields......Pro jectStaff
Link Master Fields...Projec tStaff

Is there another place to look for master/child relationships?
In this case the subform is displaying only the record that has a direct relationship based on ProjectStaff being equal. As this subform is based on a DISTINCT query it will only return one record. If you remove the DISTINCT it will return all bios for this relationship.
Nov 9 '06 #6
wjfraser
21 New Member
In this case the subform is displaying only the record that has a direct relationship based on ProjectStaff being equal. As this subform is based on a DISTINCT query it will only return one record. If you remove the DISTINCT it will return all bios for this relationship.
I left out some of the process because I thought it would confuse things...but I think I need to lay it all out. The first time I tried to make this subreport, Access truncated the bios because they were involved with the SELECT DISTINCT query. So now I run the staff list (one or more staff members listed for each project) through a SELECT DISTINCT query first, then match the resulting list with the bios from a master staff list. Like this:

qryDistinctStaf f:
Expand|Select|Wrap|Line Numbers
  1. SELECT DISTINCT [qryReport].[ProjectStaff]
  2. FROM qryReport;
  3.  
qryStaffBioRepo rt (source of the subreport):
Expand|Select|Wrap|Line Numbers
  1. SELECT [qryDistinctStaff].[ProjectStaff], [tblMasterStaffList].[StaffBio]
  2. FROM qryDistinctStaff INNER JOIN tblMasterStaffList ON [qryDistinctStaff].[ProjectStaff]=[tblMasterStaffList].[ProjectStaff];
  3.  
Taking the "distinct" out of the first query does result in multiple records being displayed, with an interesting side effect. There are the correct NUMBER of records, but they are all identical (they pull the first person's name and bio and repeat it). I will play with it a bit more but if you have input that would be great.

Thanks.
Nov 9 '06 #7
MMcCarthy
14,534 Recognized Expert Moderator MVP
OK to clarify

A group header based on projectstaff will display only one projectstaff value.

The subreport, no matter what the query will only display the record or records where the projectstaff value is the same as in current value in the group header.

Therefore, the first instance of "John Doe" will show bio for "John Doe" only in subreport.

The second instance of "Mary Black" will show bio for "Mary Black" only in subreport.

Does this make sense?

Try this query instead, should give similar results to your two queries:

qryStaffBioRepo rt (source of the subreport):
Expand|Select|Wrap|Line Numbers
  1.  
  2. SELECT [qryReport].[ProjectStaff], [tblMasterStaffList].[StaffBio]
  3. FROM qryReport INNER JOIN tblMasterStaffList 
  4. ON [qryReport].[ProjectStaff]=[tblMasterStaffList].[ProjectStaff]
  5. GROUP BY [qryReport].[ProjectStaff], [tblMasterStaffList].[StaffBio];
  6.  
  7.  
Nov 9 '06 #8
MMcCarthy
14,534 Recognized Expert Moderator MVP
One further thing...

If there is more than one bio for each staff member amend query as below:

qryStaffBioRepo rt (source of the subreport):
Expand|Select|Wrap|Line Numbers
  1.  
  2. SELECT [qryReport].[ProjectStaff], [tblMasterStaffList].[StaffBio]
  3. FROM qryReport RIGHTJOIN tblMasterStaffList 
  4. ON [qryReport].[ProjectStaff]=[tblMasterStaffList].[ProjectStaff]
  5. GROUP BY [qryReport].[ProjectStaff], [tblMasterStaffList].[StaffBio];
  6.  
  7.  
This will return all bios for each projectstaff member.
Nov 9 '06 #9
wjfraser
21 New Member

A group header based on projectstaff will display only one projectstaff value.
That does make sense. But the subreport is in the report header, not the group header.

Try this query instead, should give similar results to your two queries:

qryStaffBioRepo rt (source of the subreport):
Expand|Select|Wrap|Line Numbers
  1.  
  2. SELECT [qryReport].[ProjectStaff], [tblMasterStaffList].[StaffBio]
  3. FROM qryReport INNER JOIN tblMasterStaffList 
  4. ON [qryReport].[ProjectStaff]=[tblMasterStaffList].[ProjectStaff]
  5. GROUP BY [qryReport].[ProjectStaff], [tblMasterStaffList].[StaffBio];
  6.  
  7.  
This did not work - it stopped printing the bio altogether.
Nov 9 '06 #10

Sign in to post your reply or Sign up for a free account.

Similar topics

1
3306
by: Roger | last post by:
I couldn't find anything at http://www.mvps.org/access/reports/index.html I have a report with static (name, address, etc) in its report header and a subreport in the report's detail section the subreport has column headings in both its report and page headers (until I figure out which is best) when I print the report, the subreport headings show on the first
3
2338
by: Grim Reaper | last post by:
I know this is probably an easy question, but I could not find/figure it out. Basically, I am printing mailing labels with a "Sorting/Grouping" section that groups the label types together. Also, I am using a "Report Header" to show a count of how many total labels that are being printed. Now, my problem is that without the "Report Header", the spacing is perfect. But, when I add the Report Header, it gets shifted downwards and the...
2
4508
by: neill dumont | last post by:
I've tried to be clear, but this still seems overly complex to me, but here goes: I have a report in front of an aggregate query. I have a single subreport based on the same query for both a month/year group and for grand totals (linked on month/year) . Instead of the name of the program and the month/year, I would like: - a label on the report header to read "Monthly Summary" with the month
7
3574
by: Ellen Manning | last post by:
I've got an A2K report showing students and their costs. Student info is in the main report and costs are in a subreport for each student. The user inputs the program desired then only those students in that program are printed. I want the subreports headings to print only for the first student on the page. Is there a way to suppress printing of the headings on subsequent students on that page? I tried the following in both the...
1
1966
by: Wayne | last post by:
I have an image control in a report's detail section that gets its image from an invisible bound textbox (PhotoFile) on the report. The following code is placed in the report's Detail_Format event. Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer) Me.Image1.Picture = Me.PhotoFile End Sub I can't get this to work if I place the image control in the report header or page header and then try to use the...
5
1917
martintallett
by: martintallett | last post by:
I have a report with a text box in the page header populated with the following statement =!! Works fine on the first page of the report but gives #Name on the second and following pages... Any ideas? mt
3
3853
by: Wayne | last post by:
I have several sub-reports in the footer of a main report. In certain situations when one of the sub-reports is pushed down to near the bottom of the page by the sub-reports above it, the sub-report report header will display at the bottom of the page, but the detail displays on the next page. How can I force the sub-report header to display on the next page together with its detail?
0
1298
by: Lukas | last post by:
Hello I would like to place a "Page Header"-Section before a "Report header"- Section: {Page header} Logo ___________________________________________ * * * {Report Header}
0
1639
by: jimatqsi | last post by:
I once told a client how easy it is to make reports in Access. Since then, he's developed a savant-like ability to ask for reports that I find nearly impossible to do quickly and easily. Here is yet another example. There's a report listing sales by inventory category. At the end of this report, there is a recap that groups and totals the categories by Group and sub-group. There are 4 sub-groups in 2 broad groups, so this recap shows 6 lines...
0
9550
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10495
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10032
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7573
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6811
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5469
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5597
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4148
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2942
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.