Report Design
 Crystal Reports Forum : Crystal Reports for Visual Studio 2005 and Newer : Report Design
Message Icon Topic: Getting sub report Post Reply Post New Topic
Author Message
jayachitra
Newbie
Newbie
Avatar

Joined: 19 May 2008
Location: India
Online Status: Offline
Posts: 7
Quote jayachitra Replybullet Topic: Getting sub report
    Posted: 19 May 2008 at 4:56am
Hi all,

I am working with multiple sub reports.

As we know we can't have separate page header and footer for it.

So I inserted the objects in the main report and suppressing it based on some criteria like page nos.

But I can restrict first two page headers and footers as well as the last page by specifying the page numbers as thery were constant.

But from the 3rd page onwards it will grow based on the details.  So I am planning to get the sub report property which is identical and based on that I can impose the suppression.

But I don't know how to get the subreport property in main report. Confused

Can any one help in this regard?

Thanks a lot in advance.  
IP IP Logged
hilfy
Admin Group
Admin Group
Avatar

Joined: 20 Nov 2006
Online Status: Offline
Posts: 3702
Quote hilfy Replybullet Posted: 19 May 2008 at 3:41pm
To simulate page headers and footers in a sub report, you can do the following:
 
1.  Group the subreport on whatever field(s) you're using to link it to the main report.
2.  Turn on "Repeat Group Header on every page" for the group.
 
Voila, you now have a header on every page.
 
This doesn't work for the footer, but you can use the page footer from the main report and put something like
 
pagenumber < 3
 
in the suppression formula for it.
 
-Dell
IP IP Logged
jayachitra
Newbie
Newbie
Avatar

Joined: 19 May 2008
Location: India
Online Status: Offline
Posts: 7
Quote jayachitra Replybullet Posted: 19 May 2008 at 8:41pm
Dear Dell,


Thanks a lot for your information.

I think it will help me to solve the issue.

Regards,

M. J. Jaya Chitra.

IP IP Logged
glzhao
Newbie
Newbie


Joined: 21 Apr 2008
Online Status: Offline
Posts: 7
Quote glzhao Replybullet Posted: 10 Jul 2008 at 8:39am
Hi Jaya,
 
I am using  a subreport in my mainreport, but the problem is that the subreport does not display properly, it extends out of the area where it should be, and under other area which is in the same section as it in the mainreport. Could  you please help me solve this peoblem?
 
Becuase you said that subreport can't have a separate page header and footer, I am thinking if I should remove the header and the footer of my subreport, but I don't know how.
 
Any help would be very much appreciated!
 
glzhao
IP IP Logged
hilfy
Admin Group
Admin Group
Avatar

Joined: 20 Nov 2006
Online Status: Offline
Posts: 3702
Quote hilfy Replybullet Posted: 10 Jul 2008 at 9:59am
To solve your overlapping problem.  Insert a section below the section that the subreport is in.  Move everything that's below the subreport to the new section.
 
To "remove" the header and footer for the subreport, suppress them in the  subreport.
 
-Dell
IP IP Logged
glzhao
Newbie
Newbie


Joined: 21 Apr 2008
Online Status: Offline
Posts: 7
Quote glzhao Replybullet Posted: 10 Jul 2008 at 10:19am

Dell,

Thanks a lot! That helps me out!

glzhao

IP IP Logged
glzhao
Newbie
Newbie


Joined: 21 Apr 2008
Online Status: Offline
Posts: 7
Quote glzhao Replybullet Posted: 10 Jul 2008 at 11:08am
Hi Dell,
 
Now the subreport is overlapping with other fields horizontally. There is no help when I try to change the size of the subreport and the size of the fields.
 
Could you please give me some suggestion again?
 
Thanks in advance!
 
glzhao
IP IP Logged
hilfy
Admin Group
Admin Group
Avatar

Joined: 20 Nov 2006
Online Status: Offline
Posts: 3702
Quote hilfy Replybullet Posted: 11 Jul 2008 at 8:53am
If you change the size of the subreport horizontally, you also need to open the subreport and move things around so that they fit in the new size of the subreport.  This means that everything in the subreport needs to fit in the white part of the design pane - if it goes into the grey area to the right, your subreport will expand to fit it.
 
-Dell
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.000 seconds.