Repeat subreport over multiple pages - crystal-reports

I have a main report that has 3 sub reports in the details. I need the two sub reports, shown by the arrows on the right titled, exposure data and defect code, to repeat if the details of the sub report, shown on the left, extends more than 1 page.

Place the two subreports on the group-header instead, then set the following settings.
Activate Underlay Following Section on the group-header-section you placed the subreports
Activate Repeat group header on each page in group-expert (change group -> options tab).
If there isn't a group already, create one that doesn't change the structure of the report.
For example, if the data shown in the picture belongs to a specific location, then group by location-(id).

Related

Crystal Reports: how to repeat Details A section on every page

I'm creating a report in Crystal. It's a pretty basic report: I have two groups based on the same date field: year and month.
Those two groups serve as a way of organizing my details. I have the details hidden so they can be drilled down upon.
So when you first view the report, you just see the year(s) for group 1, and then the months for group 2.
If I wasn't using the grouped dates in this way, and was just creating a basic table, I would put the field headers in the page header section, which would automatically put the field headers on every page. However, since I have the grouped dates (hiding the details) on my first page, I can't put the field headers in there.
As a result, I created two detail sections (A and B). I put my field headers in A with the suppress formula (not onfirstrecord). This serves my purpose, but for when the report details fill up multiple pages, my Details A sections will only display on the first page.
Is there some formula or other way for me to:
1) Keep my field headers in Details A, but repeat the field headers on each new page?
2) or, move my field headers to the Page Header section, but somehow suppress it when my groups are being displayed on my main page (where the year and month groups can be drilled down on)?
Thank you!
You may want to use a repeated group header.
To do this open the Change Group Options dialog (right click on a group header, then choose Change Group). On the Options tab check Repeat Group Header On Each Page.
Put your headers for your detail section in a group header (maybe an additional one just for this purpose). Repeat this header on each page.
You can even detect if the header is printed the first time or if it is repeated using InRepeatedGroupHeader. This way you can implement a 'continued' on a repeated group header.

How to get a page per register stored in DDBB in jasperreports?

I have a report with the following structure:
PAGE HEADER
DETAIL BAND (12 of those)
SUMMARY BAND
The detail bands show depending on expressions I specified. Also, the content of the detail bands are subReports, one per detail band (don't know if that is relevant or not here).
What I'm trying to achieve is to execute the report without any filter as the ID or any other field of the table. Instead, I want to extract the information of all the registers of one specific table (let's name the table USER).
What I'm expecting to find when I execute the report is something like the following:
PAGE HEADER
detail sections (shown depending on the expressions )
SUMMARY
What I'm getting looks similar to the following:
PAGE HEADER
DETAIL 1 (for user1)
DETAIL 2 (for user1)
DETAIL 1 (for user2)
DETAIL 4 (for user3)
and never the summary band (just at the end of the report)
As you can see, all the users are getting mixed while what I want to do is to start a new page for each one of them.
QUESTIONS:
How can I get the report to show each one of the users from the table
in separate pages?
Is there some property I missed that allows me to
do that?
Thanks!
I think I found a way to solve this challenge. I just made a group (Group1) based on the ID's of the users and put the content of my Page Header inside the Group Header just created. Did the same with the Summary band, put all it contents inside the Group Footer.
Then, selecting the Group Header (or the Group Footer) I checked the Keep Together and the Start New Page checkboxs from the Appearance tab.
Furthermore, for each one of the detail bands, selected the Group1 just created for the Group Changes selection combo in the Appearance tab.
I didn't do much testing yet but it seems like it's working as I wanted it to. If I find any other (better) solution I'll update the answer. Still open to hear advices though.

Underlay Chart with Detail section

My group header has a chart and records in the detail section.
I placed the chart on the left side of the page and the columns of the table (in detail section) to the right. Now i just want them to be side by side. I already tried to set in expert mode the underlay following section in the group header but this will not work. the data source for the chart is a nother than the one for detail section, so Im using suppressing in detail and group.
Take a sub report and place in group header and limit the size of the sub report to the the extent required and don't touch the graph.
Now in sub report place detail data and display

Split page details in crystal report to contain many data

I'm using crystal report XI release 2 to make a report from SQL Server views
View 1 : OrderDetails
View 2 : SalesMen
OrderDetails contains only one record but SalesMen contains 5 records
i want to add both data in one page but i don't know how because when i add data from SalesMen it also repeat all data from OrderDetails and when choose Suppressed If Duplicated on all field in OrderDetails it's leave a blank area for unrepeated data which make very large spaces
Check the following images for more description
This how i want it to be like
and this is how it looks like
Note : And what if i have 2-3 views that contains several records and i want to show them in the same page?
Okay i've got what i was looking for
the solution is very simple, Create an sections inside details then create a sub reports and add it inside the section like the following steps
1 - Right click report body then select Section Expert
2 - From section tab click on details then insert sections as much as you want to add separate sections then press ok
3 - From crystal report main window click insert then click subreport
4 - name your sub report and add what you want
5 - insert the sub report inside the section you made
you can add it horizontal or vertical it's up to you.

Break Detail Line in Half?

Currently the detail prints like this:
I want to break the line in half like this:
This is what I have; Not what I want
Notes:
This is all in a sub-report if that makes any difference
I do not yet grok using formulas, variables, etc. to influence what is printed where, when, or how.
I'm working in Visual Studio 2012, I don't know the CR version.
I created Detail a and Detail b sections.
I created 2 Group Header Sections: Group Header 1a and Group Header 1b
I moved all the headers into these two groups and suppressed the Report Header Section (but not the Report Footer). Moved report fields into corresponding detail group.
Now all the detail is printed after both headers are printed. I expected this but don't know how to do what I need.
Totals are printed in the Report Footer, no issues here.
The Mystery is Solved
Created a 2nd sub report
Moved desired headings, details, and totals to the new sub report ReportHeadr, DetailSection, and ReportFooterSection respectively.
Put the new sub report directly below the original in the same (main report) section - it just happens to be a GroupHeaderSection
Changed SubReport Links ... for the new sub report. Set it identically to the original.
Notes
The sub report links setting is key to making this work. Otherwise I was getting all the data records every time this new sub report was generated, resulting in hundreds of pages.
Could not use Siva's answer. The sub report happens to be inside a Main Report's GroupHeaderSection. The report's structure does not make putting the (sub report) content into new groups and detail sections possible.
I did create multiple groups & detail sections in the sub report itself. This still gives me the undesired results illustrated in the original question posting.
if you need to view the output as you required follow below
1. Take 2 detail sections add two sub reports in main report.
2. In sub report 1 place first 3 columns and in second sub report place other two columns