Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Regd no data in SUB Reports

Status
Not open for further replies.

longfellow

IS-IT--Management
Mar 28, 2002
75
IN
dear all

In some subreports i select data from my DB tables . After the subreport i have text items . Sometimes if there is more data , the subreport overlaps on the text data and everything becomes distorted. And if i try to increase the Details section's length it gets sorted out. But when there is no data , all the blank space created previously gets displayed in the report now. And if the data crosses say 20 pages or so i cannot keep on increasing the details section know.Is there any way i can sort this problem out.

Please reply immediately

Thanking you in advance
Longfellow
 
Split the section into A and B subsections, and put the subreport in A and the text in B. This should allow the sub to grow without overlapping the text. Ken Hamady, On-site Custom Crystal Reports Training & Consulting
Public classes and individual training.
Guide to using Crystal in VB
tek@kenhamady.com
 
In runtime if no data is retreived for the subreport how do i hide that section which contains this sub report .
Please Reply Immdly

Thanking you in Advance

Longfellow
 
Suppress all of the visible sections in the subreport with the following formula:

IsNull( {AnyRequired.field} )

Then make the subreport object and section as short as possible on the report (it will grow to the needed size). Ken Hamady, On-site Custom Crystal Reports Training & Consulting
Public classes and individual training.
Guide to using Crystal in VB
tek@kenhamady.com
 
Can you give any example regd the same. I am not able to understand as to where i should use this
IsNull( {AnyRequired.field} ). I need it very badly

Thanking you

longfellow
 
Go into "Format - Section".
Select any section that is currently visible in the report.
Click on the 'pencil' button to the right of the suppress property.
Put the formula in there. Ken Hamady, On-site Custom Crystal Reports Training & Consulting
Public classes and individual training.
Guide to using Crystal in VB
tek@kenhamady.com
 
I was trying this but sometimes when data was there the sub report was getting suppressed. I did not understand why this was happening.
Its like this

When a student fails in the exam all his details for the class which he is studying should not be displayed in the subreport displaying records of students who have passed the exam. How do i make this happen.
If in a semester only 2 students are there and both did not appear for the exam then there will be no data available about them in the DB . Instead of siplaying blank spaces as it displays now a message like " no students appeared for the exam " should appear in place of the sub report.
Can i do this in CR 7 ? How do i try to do it.

Thanking you

Longfellow
 
If the report suppresses when there is data, then you may not have selected a required field for your formula. That field may be null even when records exist.

To get your message, put it in a subsection of the report header. Then, suppress this subsection with the condition:

Not IsNull( {AnyRequired.field} ) Ken Hamady, On-site Custom Crystal Reports Training & Consulting
Public classes and individual training.
Guide to using Crystal in VB
tek@kenhamady.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top