Report Design
 Crystal Reports Forum : Crystal Reports .NET 2003 : Report Design
Message Icon Topic: how to show only 5 records per page in crystalrepo Post Reply Post New Topic
Author Message
mukta
Newbie
Newbie
Avatar

Joined: 04 Apr 2011
Location: India
Online Status: Offline
Posts: 19
Quote mukta Replybullet Topic: how to show only 5 records per page in crystalrepo
    Posted: 04 Apr 2011 at 11:43pm
Plz anyone can tell me how to show 5 record per page in crystal report?
IP IP Logged
hilfy
Admin Group
Admin Group
Avatar

Joined: 20 Nov 2006
Online Status: Offline
Posts: 3702
Quote hilfy Replybullet Posted: 05 Apr 2011 at 3:28am
1.  Create a running total that counts your records.  I'll call it (#RecCount}.
 
2.  Right-click to the left of the details section where your data is displayed and go to the Section Expert.
 
3.  If you're in Crystal 2008, go to the Paging tab (I believe that's what it's called - I don't have a copy of Crystal available to check) .  For earlier versions, there are no tabs.
 
4.  Click on the button to the right of "New Page After" - DO NOT check the checkbox!
 
5.  Put the following in the formula editor:
 
{#RecCount} mod 5 = 0 and not OnLastRecord
 
This will give you a page break any time the number of records is a multiple of 5, but no page break at the end if the total number of records is a multiple of 5.
 
-Dell
IP IP Logged
mukta
Newbie
Newbie
Avatar

Joined: 04 Apr 2011
Location: India
Online Status: Offline
Posts: 19
Quote mukta Replybullet Posted: 05 Apr 2011 at 10:39pm
Thank you very much sir.
but first it displays 1st page and 2nd page properly and if  i click on last button then it goes to last record properly.

but problem is that

 when i clicked on next page(3) then it shows only again 2nd page again do not go further.

tell me solution sir..

i wrote  like
recordnumber mod 3 =  0 and not OnlastRecord

its working but geting above problem..
Reply me.. sir

IP IP Logged
hilfy
Admin Group
Admin Group
Avatar

Joined: 20 Nov 2006
Online Status: Offline
Posts: 3702
Quote hilfy Replybullet Posted: 06 Apr 2011 at 2:44am
What version of Crystal are you using?  Do you have all of the service packs installed?  I think I recall that this was a problem in one version that was fixed in a service pack, but I may be wrong.
 
Are you using a built-in "recordnumber" special field (I've never used it, so I'm not sure whether it exists and I don't have Crystal on this computer)?  If so, you could also try this using a running count.
 
Oh, and I'm not male, so you don't need to call me sir! Big%20smile
 
-Dell
IP IP Logged
mukta
Newbie
Newbie
Avatar

Joined: 04 Apr 2011
Location: India
Online Status: Offline
Posts: 19
Quote mukta Replybullet Posted: 07 Apr 2011 at 9:23pm
Sorry Madam...

k Madam I am using crystal 2005.
I am using built in recordnumber. i dont know how to count records by using running count. Can u tell me?
above my code is working only when we browse our report at design time.but not wen we browse page on internet explorer..

n Madam can u tell me how to add border to pages in crystal report.
IP IP Logged
hilfy
Admin Group
Admin Group
Avatar

Joined: 20 Nov 2006
Online Status: Offline
Posts: 3702
Quote hilfy Replybullet Posted: 08 Apr 2011 at 2:45am
Running count - In the Field Explorer you'll see an option for "Running Totals". Create a new running total and do the following:
 
1.  Select the field you want to count - usually this will be an ID field of some sort that is distinct for each record.
 
2.  Change the sumary to "Count".
 
3.  Reset - never.
 
Use this value in your formula.
 
Borders - I assume you mean a line border, correct? 
 
1.  Draw a box that goes from the top of the page header section to the bottom of the page footer section. 
 
2.  Right-click on the box and select the Format option.  There should be a checkbox that says something about closing the box at the end of a page - I don't have Crystal on this workstation so I can check the exact wording.  You want to have that checked.
 
-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.016 seconds.