Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Report Design
Message Icon Topic: Set DetailSection Height Post Reply Post New Topic
Author Message
karthikkjm
Newbie
Newbie
Avatar

Joined: 19 May 2011
Online Status: Offline
Posts: 21
Quote karthikkjm Replybullet Topic: Set DetailSection Height
     Posted: 05 Feb 2013 at 6:23pm
How to set Detail Section Height through C# (.net 2.0) Code. i am using Crystal Reports V10.2.

i have group header also, that means i need to control the height of Group header + Details Section.

how to do that, when the height set reached, i need to activate new page after...

thanks in advance
karthik K
karthik
IP IP Logged
lockwelle
Moderator
Moderator


Joined: 21 Dec 2007
Online Status: Offline
Posts: 4374
Quote lockwelle Replybullet Posted: 07 Feb 2013 at 6:11am
paging is solely through the report, you cannot program that into the report.
 
What I mean is that you can write a formula to make a new page in the report, but I doubt you can do it from C#. Also there is no reliable way to do this unless you count the rows on the report (or you can use the size of each section on the report...same difference). But if you have a cell that 'Can Grow' turned on, all bets are off as CR does not tell the size of anything displayed, nor does it give you a way to determine what happened. You can guess at the size, but if you are proportional fonts, you don't even know how long it displays as, so counting lines is as good as any method.
 
As for setting the size, you might be able to do that from C# if you know the control name, I've never done it, so I am not positive that you can do this. The only caveat that comes to mind is that you multiply by 1440...if you want a section to be 1" tall, since CR uses twips, you would need to convert the 1" to 1440 twips.
 
HTH
IP IP Logged
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