Solved

Row Number in Group, For Each Group Row Number must start from 1

Posted on 2011-02-23
2
1,060 Views
Last Modified: 2012-05-11
hi experts, i am using Crystal report 11,
i want to start Row Number for each group. e.g.  Cash and Credit there are two group having some data, I need  Below restult
Cash
1       ahmed ali
2       akbar ali
3       sarfraz ahmed
Credit
1      basit afzal
2      javid akram
3      Imran Khan

Note: i have written code  but my each row gives me 1  instead of 1, 2 ,3 .....
Please correct my code,  or give me other code to full fill my requirement.



In the report header
Name - DeclVars
Formula
global numbervar RecCount := 0;
""

In the group header
Name ResetCount
Formula
global numbervar RecCount;
RecCount := 0;
""

In the detail section
Name IncCount
Formula
global numbervar RecCount;
RecCount := RecCount + 1;
RecCount;        
0
Comment
Question by:mahmood66
2 Comments
 
LVL 100

Accepted Solution

by:
mlmcc earned 500 total points
ID: 34967423
Crystal by default evaluates formulas as early in the process as possible.  However it only retains values for formulas in the Printing pass.  To forcec a formula to be evaluated in a particular pass you can add an evaluation time command to the formula

Add WhilePrintingRecords; as the first line of each formula.

WhilePrintingRecords;
global numbervar RecCount := 0;
""

mlmcc
0
 

Author Comment

by:mahmood66
ID: 34967446
Thanx a lot for your quick support dear,
same thing i have done using running Total and reset at group(i select Group Name from list).
anywho than againt.
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Not Exists 3 74
Dynamic Image won't display if no data is returned 11 65
Crystal reports subreports as total of main report 13 74
shared number array to be used in subreport 8 32
Crystal Reports: 5 Tests for Top Performance It is complete, your masterpiece report.  Not only does it meet your customer’s expectations, it blows them out the water, all they want is beautifully summarised and displayed in a myriad of ways. …
Hello everyone, Hope you find this as helpful as we did. We have on the company I work for an application built in Delphi V with Crystal Reports 8. We all know that Crystal & Delphi can be temperamental sometimes and the worst thing is, nearly…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

821 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question