Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Record Number Resetting 3

Status
Not open for further replies.

jorg32

Programmer
Jul 10, 2003
57
BE
Hi,

I've made a list where every Detail line got a number (Record Number).
How can I stop this count and start again from '1' when I use a new page and/or when it starts with a new client,....?

Thanks for helping me.

Jorg
 
you will need to use variable to accomplish this.

Create 2 formulas

Forumula 1 - place this in the page header section and in the Client Group Header section (these can both be supressed)

//@Reset
WhilePrintingRecords;
Shared NumberVar RecordNo := 0;

Formula 2 - Place this in the Details section

//@RecordNo
WhilePrintingRecords;
Shared NumberVar RecordNo := RecordNo + 1;
RecordNo

HTH

Gary Parker
MIS Data Analyst
Manchester, England
 
This works, but when I use a Detail 'a' and Detail 'b' (surpressing always one of this 2), the first 2 lines have always the same number!?
e.g. : Line 1=1, line 2=1, line 3=2, ....

What do I have to change?

thx
Jorg
 
use the RecordNo formula in Detail Line 1 and use this formula in Detail Line 2

//@RecordNo2
WhilePrintingRecords;
Shared NumberVar RecordNo;



Gary Parker
MIS Data Analyst
Manchester, England
 
Hi Gary,

I hope this is the last question about this issue :

What do I have to put extra in the formula when 1 client have more than one page.

With this formula I've got on each new page, new numbers.

Thx
Jorg
 
If you only want the counter to reset for each new client then remove the Reset formula from the page header

Gary Parker
MIS Data Analyst
Manchester, England
 
Of course!!
I think it is time to go home because I cann't think clearly anymore with all the work that I have here :))

Thx again Gary !!
Have a nice weekend.
Jorg
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top