Solved

Subreports Record count

Posted on 2006-07-12
5
590 Views
Last Modified: 2008-01-09
Hi All,

I have a subreport inside a main report . the structure is like

GH1 Invoive No
GH1A Subreport --> Invoice Detail
GF1

Subreport is linked with main report with InvoiceNo

The Group Header 1 contains invoice number
the Group Header 1A contains subreport with Invoice details.

Now i want to suppress the GH1 section of main report if its subreport does not contain any record.

Please help me

regards
Vishal
0
Comment
Question by:vishalgoyal123
5 Comments
 
LVL 5

Expert Comment

by:dkDeveloper
ID: 17090559
Hi vishalgoyal123,

I was wondering what your data source is for this report.  Could you include a count of the detailed line items along side the invoice number and then just conditionally suppress when that count is equal to 0?  If not, I'm afraid this might not be possible since the processing of the subreport occurs after the section you wish to suppress.

Good Luck!
dK
0
 
LVL 42

Accepted Solution

by:
frodoman earned 48 total points
ID: 17093870
dk is right on the money - you can't suppress one section based on the results of a subreport in a subsequent section.

If you can return the count in your primary recordset that's probably the most efficient.  If not, you may be able to run a separate subreport prior to the section that does not but count the records and share the result with the main report.

frodoman
0
 
LVL 34

Assisted Solution

by:James0628
James0628 earned 47 total points
ID: 17095262
Another option might be to eliminate the GH1 section and put whatever was there in the subreport.  Then perhaps the subreport can suppress it if there are no details.  Whether or not that will work will depend on the details of your reports and data.

 James
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Hot fix for .Net Crystal Reports 10.2.3600.0 to fix problems with sub reports running on 64 bit operating systems ISSUE: Reports which contain subreports fail with error "Missing Parameter Value" DEPLOYMENT SERVER OS: Windows 2008 with 64 bi…
There have always been a lot of questions related to when Crystal Reports evaluates report components (such as formulas, summaries, cross-tabs, charts, to name a few examples). Crystal Reports uses a two-pass reporting process to provide greater …
Microsoft Active Directory, the widely used IT infrastructure, is known for its high risk of credential theft. The best way to test your Active Directory’s vulnerabilities to pass-the-ticket, pass-the-hash, privilege escalation, and malware attacks …
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question