Tips and Tricks
 Crystal Reports Forum : Crystal Reports for Visual Studio 2005 and Newer : Tips and Tricks
Message Icon Topic: Problem with printing n number of lines on report Post Reply Post New Topic
Author Message
charlese
Newbie
Newbie


Joined: 21 Apr 2011
Online Status: Offline
Posts: 33
Quote charlese Replybullet Topic: Problem with printing n number of lines on report
    Posted: 26 May 2011 at 1:32am
I am having a lot of problem with making my report displaying only n number lines in my two subreports and would be so grateful if anyone can please shed some light.

My scenario is I can have one or more report index. For each report index I can have multiple detail invoice. If I have got 15 invoice lines for one report index, I want to print 10 lines on page one and the other 5 lines on page 2 for each subreport.

The invoice details section has been designed using sub report and I have got 2 detail section on my report i.e details a, details b. They both will print the same information. Detail a will be the copy for the firm and detail b will be the copy for the client.

So on my Main report, I have got:
- report header
- page header
- group header (for the report index)
- detail a (which contain the first subreport )
- detail b (which contain second subreport)
- detail c (which will contain the cheque, this is not got a subreport)

In my subreport a, I have created a formula to count the number of lines in the subreport i.e.

WhilePrintingRecords;
Shared NumberVar LineCounter ;

LineCounter := LineCounter + 1 ;

what I want to do is tell CR to stop printing when the lineCounter reaches 10 in detail a. But to continue to print the 10 invoice lines in detail b for the client section and also print the cheque in detail c. Then do a   page break, then continue the next 5 lines on the next page 2.

Please help anyone....

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.031 seconds.